Answered
How to read a text file into a numeric array?
This was a tricky one. I was able to get something in, but there are extra rows at the end that aren't importable. This file ap...

2 years ago | 1

Answered
How to put a string in a text file to define headers to data?
The issue is here: fprintf(filename1, '# GHz S DB 50'); fprintf doesn't accept a file name, it need an open, writable file-id ...

2 years ago | 0

| accepted

Answered
Reading csv file NaN and NaT problem
Based on the description, I think this is what you'd want. Without an attached file, I cannot say more. opts = detectImport...

2 years ago | 0

Answered
How to use textscan to read my 2nd column and ignore the string or non numerical values?
I suggest trying opts = detectImportOptions(filename) T = readtable(filename,opts) Also, if you want to ignore those...

2 years ago | 1

Answered
xlswrite randomly overwrites entire spreadsheet!
I suggest trying in a newer version of MATLAB. If it works there, contact technical support to report the bug. I'd also sugg...

2 years ago | 0

Answered
Issue with data format when using textscan()
The format should be all lower case for duration. %{hh:mm:ss}T However, the data appears to be delimited as semicolon. Y...

2 years ago | 1

| accepted

Answered
MatLab doesn't read my .TXT file correct
Thanks for uploading the file! The first issue I see is that the file has a UTF-16 byte-order-mark. The file is stored as UT...

2 years ago | 4

| accepted

Answered
Trouble loading in mixed data from txt file
You're adding 'CollectOutput' which is concatenating all the numeric columns into one. If you remove that, you should get the nu...

2 years ago | 1

| accepted

Answered
Yet another TEXTSCAN question...
If the numbers are always surrounded by double-quotes, try this, t = textscan(s,'"%f""%f""%f"','Delimiter',',') or, ...

2 years ago | 0

Answered
" Error using readtable (line 198) An internal error occurred ". How can I solve this issue?
I tried, T = readtable('Nuevo.xlsx') T = readtable('Nuevo.xlsx','Basic',true) And both worked for me. Sometimes the ...

2 years ago | 1

Answered
readtable function ignores certain options
READTABLE uses the variable names defined in the Options over the ones in the file. This is because you can re-use the options o...

3 years ago | 0

Answered
error using readtable with "opts" and "TreatAsEmpty" together
Hi, Only a subset of the parameters in READTABLE are allowed with the options. Part of the reason is that, in the import opti...

3 years ago | 1

| accepted

Answered
reading in text files
You should try |tabularTextDatastore| assuming everything has the same format. ds = tabularTextDatastore(pathToFiles) ds...

3 years ago | 1

Answered
Convert timestamps in CSV file to seconds using readtable and table2timetable
This will work as long as the times are on the same day (as in the file). T = readtable(file,'Format','%{dd-MMM-uuuu HH:m...

3 years ago | 0

| accepted

Answered
readtable can't get variable names from csv if different number of columns
Try giving a hint. opts = detectImportOptions(filename,'NumHeaderLines',0); T = readtable(filename,opts)

3 years ago | 4

| accepted

Answered
Error when synchronizing two time series
Hi, I think this is a simple fix, this code may not do what you think it's doing: t1 = SP(:,1); % is a table I don't thi...

3 years ago | 0

Answered
large csv import and split
With a file that's 25GB, you're going to need to break the data up. I recommend using ds = tabularTextDatastore(filename...

3 years ago | 0

Answered
Hello .. how to read a text file which is a matrix of [1000x512] order of complex numbers. could anyone please help me over this
Hi Darapu, This worked for me. T = readtable('Extracted_Dry_Tar_Road_prediction_file.txt','Whitespace',' ()'); T.Va...

3 years ago | 1

| accepted

Answered
readtable does not allow 'Format' option
Hi Xiaoyu, If you're using R2016b or later, you can specify details like this with spreadsheet import options. opts = de...

3 years ago | 0

Answered
Error Message dataread and textread
Hi George TEXTREAD is trying to import numeric data but encountering text fields which cannot be converted. Basically, your f...

3 years ago | 0

Answered
Textscan and csv fitness data problem
Hi Using textscan is great if you have files with varying formats or if you need certain special behaviors. I found this on...

3 years ago | 0

Answered
Process .csv file, combine first two rows into 1 (text rows) to make them the variables
You could try using <https://www.mathworks.com/help/matlab/ref/detectimportoptions.html detectImportOptions> (R2016b or later) a...

3 years ago | 1

Answered
Problems With readtable. Convert string data in datetime with milissecond precision.
Your time seems to have a decimal separator of '.' it's the semicolon that's the issue. t = readtable('Test2.csv','Format',...

3 years ago | 0

Answered
Fast move in datastore (TabularTextDatastore)
Hi Adam, Unfortunately, there's not a way to do this. (And I don't mean with datastore--text files are linear things... to fi...

3 years ago | 2

| accepted

Answered
Subscript indices must either be real positive integers or logicals
Very common error. =) MATLAB arrays start at index = 1. You should see the same error from x(0,:) = 1. In this case, I don't ...

3 years ago | 0

Answered
How to import multiple csv files into one and read it from certain folder?
You can use tabularTextDatatstore to collect the CSV files and read them into one table >> ds = tabularTextDatastore(filepa...

3 years ago | 2

| accepted

Answered
How do I read this csv file in and convert the dates?
Hi, I have two things. The first is that readtable should recognize the format, and return datetimes (assuming you are in a...

3 years ago | 0

| accepted

Answered
Long time to load 40 gig file
"cell array tables" A good bet is that the cell arrays are the issue. Each cell of the array takes a 114 bytes of overhead. W...

3 years ago | 0

Load more