MATLAB Answers

Info

This question is closed.

I find there is some problem with the importdata function import data, there is some data without negative character?What is the reason?

13 views (last 30 days)
huazai2020
huazai2020 on 5 Jul 2020 at 16:38
Closed: Stephen Cobeldick on 6 Jul 2020 at 14:54
I find there is some problem with the importdata function import data, there is some data without negative character?What is the reason?
The below is the code:
clc;clear all;
filec=importdata('xcood-020.txt');
data(:,1)=filec.data;
please see the data file attached. How to deal with it ?

  0 Comments

Answers (1)

Image Analyst
Image Analyst on 5 Jul 2020 at 16:45
I don't know. I think maybe all the minus signs in the string on each line might be confusing it. Try readmatrix:
data = readmatrix('xcood-020.txt')

  0 Comments

Tags


Translated by