Answered
How to import data into a dataset from a space-delimited ascii file.
Mark, I think you're going to need to use MultipleDelimsAsOne for this file. To do that, you're gonna need to pass in a format, ...

10 years ago | 1

| accepted

Answered
Need to output my data which is currently in a for loop to a table!
Olivia, all you have are strings, and presumably you want one column of strings and eight columns of numbers. TastyPastry's sugg...

10 years ago | 0

| accepted

Answered
help writing a script that tells the day of the week
... and another way, using datetime (if you have R2014b or later): >> d = datetime('08/31/2011','InputFormat','MM/dd/yyyy')...

10 years ago | 0

Answered
Conversion of dates to a different format
In R2014b or later, use datetime. Convert a yyyyMMdd string to a datetime: >> d = datetime('20110530','Format','yyyyMMdd...

10 years ago | 1

Answered
How to plot part of Date column vs Data
In R2014b or later, try this: d = ( datetime('31-Jul-2013 10:59:50'):seconds(10):datetime('04-May-2015 12:45:10') )'; x ...

10 years ago | 0

| accepted

Answered
Convert date to UNIX time
In R2014b or later, use datetime: >> d = datetime('24-Apr-2011') d = 24-Apr-2011 >> posixtime(d) ans = ...

10 years ago | 6

| accepted

Answered
How to get string that uses datetime Format property?
Bruce, in your C.S-S.M post, you said, "write data and labels to a file". It's worth noting that if you have everything in a tab...

10 years ago | 0

Answered
How to insert char to table?
Emmanouil, it's pretty hard to answer this for sure without more info. But assuming that you have a table like this >> out2...

10 years ago | 0

Answered
readtable bug - if file has only one line, then readtable throws error ONLY if ReadRowNames = 1
cmo, you are correct, thank you for finding this bug. I will make a note to have it fixed. For the time being, you can read in t...

10 years ago | 1

Answered
Is there a simpler way to create an empty Table with a list of VariableNames?
Andrei, Walter's solution works, as would optionsChange = array2table(zeros(0,9), 'VariableNames',{...}); or even o...

10 years ago | 13

Answered
readtable truncates rownames if using ReadRowNames
cmo, you are correct, thank you for finding this bug. I will make a note to have it fixed. For the time being, you can read in t...

10 years ago | 1

| accepted

Answered
Rounding Time to next half hour
In MATLAB R2014b or later: >> d1 = datetime({'9/8/2015 14:31:01', '9/8/2015 14:31:02', '9/8/2015 14:31:03'}) d1 = ...

10 years ago | 2

Answered
Problem with importing Date & time from Excel
Sangjun, it sounds like you're using a version of MATLAB prior to R2014b, so Walter's suggestion won't work. I'm assuming you...

10 years ago | 1

Answered
Extracting Table Data by Date
Andrew, everything dpd said sounds right, but let me just start over. You're using date strings because they're easy to read. Fa...

10 years ago | 0

| accepted

Answered
Timezone to UTC: How do I add duration vector to datetime vector?
Frank, what's up is Daylight Saving Time, which occurred on March 8th this year. I'm guessing you knew that, but got mixed up in...

10 years ago | 4

| accepted

Answered
convert table to array or matrix
There are two ways to converta table to a (numeric in this case) array: 1) call table2array 2) use {} subscripting for the v...

10 years ago | 0

Answered
using of tables for questionnaire answers
Marta, you should provide a short example of your data so that it's clear what you have.

10 years ago | 0

Answered
When using Readtable, how do I convert column of data from text to date?
NJBadger, two suggestions: 1) If you use the Import Tool rather than readtable, you can read directly to a datetime variable ...

10 years ago | 0

Answered
Use of time Series
Cedric, while the timeseries class does not support datetime arrays, it does have methods to synchronize or resample time series...

10 years ago | 0

Answered
cell to string to date time
Samantha, it sounds like you have code that you generated using the Import Tool. When you import a text file using the IT, you c...

10 years ago | 0

Answered
Improve speed to max calculation for max daily output
There are lots of ways to do this. Here's one that assumes you have R2014b or later. If you only have R2013b or later, you can s...

10 years ago | 0

| accepted

Answered
Why can't I access day, juliandate?
KE, just to be clear, if you have MATLAB R2015a, then you have datetime, along with its day and juliandate methods. No extra too...

10 years ago | 0

Answered
Why can't I access day, juliandate?
KE, day is a function in the Financial Toolbox, and juliandate is a function in the Aerospace Toolbox. The fact that you're aski...

10 years ago | 1

Answered
How to do monthly average in a Table?
Even without Statistics And Machine Learning Toolbox (or Statistics Toolbox prior to R2015a), the varfun method of table also do...

10 years ago | 5

| accepted

Answered
Find three largest and smallest values in column of table
As Walter said, this is just sorting. In R2013b or later, use a table: >> asset = {'a'; 'a'; 'a'; 'b'; 'b'; 'b'; 'c'; 'd'; ...

10 years ago | 1

Answered
Advice on Indexing A table.
Let's assume you have these in your workspace: >> x = [35 36 38 38 38 38 38 38 38 38 46 46]'; >> date = {'24/07/2014' '0...

10 years ago | 0

Answered
Divide column 17 of table by 365
More directly: x.Var15 = x.Var15 / 365 % or whatever the 15th var is named or x.Var16 = x.Var15 / 365 % or whatever...

10 years ago | 0

Answered
As I can compare rows in a column?
The followup discussion in this thread is not exactly clear, but if the goal (as stated in the original post) is to "divided int...

10 years ago | 0

Answered
Monthly Average for Large Dataset
Hard to tell if that file is space- or tab-delimited, and if that's the top of the file, or what. It helps to provide more preci...

10 years ago | 0

Answered
How to select one column of data from a csv file containing headers and strings?
It's not clear what you mean by, "save them into a table". It sound like you mean, "save that one column to a numeric variable"....

10 years ago | 0

| accepted

Load more