Community Profile

photo

Peter Perkins

MathWorks

Last seen: 3 días ago Active since 2011

Statistics

All
  • Personal Best Downloads Level 1
  • 5-Star Galaxy Level 3
  • First Submission
  • 36 Month Streak
  • Guiding Light
  • Thankful Level 1
  • Revival Level 2
  • Knowledgeable Level 4
  • First Answer

View badges

Content Feed

View by

Answered
How to sum structures
Assuming that you are starting with something like this >> A.X = table(rand(3,1),rand(3,1),'VariableNames',{'X1' 'X2'}); >> A....

alrededor de 1 mes ago | 0

Answered
How to add two sets of imported data?
Ashley, there's a long example in the doc that talks about "how to perform calculations by using the numeric and categorical da...

alrededor de 1 mes ago | 1

Answered
Finding the difference in timeseries values
David, you are correct that diff(TableName.Variables) removes the times and the variable names, in fact, it returns a numeric ma...

alrededor de 1 mes ago | 0

Answered
Can I use the movmean function for a time series?
CivilEngBath, I recommend that you take a look at using timetables, not timeseries. smoothdata on timetables does what you want....

alrededor de 1 mes ago | 0

Answered
Plot data to a certain date with array
Give this a try: >> tt = timetable((1:365)','RowTimes',datetime(2021,1,1:365)) tt = 365×1 timetable Time Var...

alrededor de 2 meses ago | 0

Answered
Replacing missing data in timetable with values from another dataset
IIUC, I think the simplest thing to do would be to remove the rows with missng data, vertically concatenate with the other data,...

alrededor de 2 meses ago | 0

| accepted

Answered
How to convert timeseries class mat file to excel
In MATLAB R2021b, you can use timeseries2timetable, and then write the timetable to excel. This timeseries has nothing complica...

alrededor de 2 meses ago | 1

Answered
select the correct row in a table with a different index in the for loop
Giulia, you got an asnwer to your specific question, but it's quite possible that you asked too specific a question, and didn't ...

alrededor de 2 meses ago | 0

Answered
Error with the division
As StarStride hints, these tables are not even the same size, in either dimension: >> DATIECMWFannuali DATIECMWFannuali = 2...

alrededor de 2 meses ago | 0

Answered
How can I delete this data on the graph?
This is a lot of code that I just can't follow. I will suggest that a loop l;ike this for i=1:length(dates) % per ogni coppia...

alrededor de 2 meses ago | 0

| accepted

Answered
How to add variable to Table in MatLab App Designer ?
There are probably a couple things wrong with app.Table{1}=(app.A) First, if app.Table doesn't yet exist, you are not creating...

alrededor de 2 meses ago | 1

Answered
Remove successive rows from a table where a specific column value is duplicated
rowfun would be one way to get Jon's suggestion of using unique to work: >> t = readtable("Metingen-data-2021-11-17 10_48_18.cs...

alrededor de 2 meses ago | 0

Answered
Add variables from one timetable to another
Eric, I think all you need is >> T1 = array2table(rand(5,3),"VariableNames",["A" "B" "C"]); >> T2 = array2table(rand(5,3),"Va...

alrededor de 2 meses ago | 0

Answered
Iterate and convert datenums to date times, and find time durations
A couple of preliminaries: xlsread is not recommended. readtimetable is what you want. '200007130000' isn't a "datenum", that ...

alrededor de 2 meses ago | 0

Answered
how to find the average of a table 366-by-6
Another possibility would be mean(T{:,vartype("numeric")},"all") But beware, the {} there will downcast mixed numeric types.

alrededor de 2 meses ago | 2

Answered
How to import Excel table with column of as individual variables?
I don't know that readtable is the way to go here. If you really just have a few named scalars, you might think about readcell (...

alrededor de 2 meses ago | 1

Answered
Finding A String In A Specific Column of A Table (SQLite)
If this were a MATLAB table, it would be something like endsWith(T.StringVar,"sixChr") but I don't know what context you are w...

alrededor de 2 meses ago | 0

Answered
joining two timetables to complete the timeseries
Muhammad, join is sort of like a horizontal concatenation operation. That is not, I think, what you are looking for. You say I ...

alrededor de 2 meses ago | 0

Answered
Adding a new column of differences to a table
Even simpler: T.diffB = [0;diff(T.B)]; T.diffC = [0;diff(T.C)]; David's soln has the advantage of being easier to write when ...

alrededor de 2 meses ago | 0

Answered
Is there any better way to find the average of a dynamic signal for a specific time like 10s or something.?
Why would you not use mean? In any case, make a timetable, and use something like retime(tt,'regular','mean','TimeStep',second...

alrededor de 2 meses ago | 0

Answered
Organising Dates based on User ID and compute weekly average
If it's just counting number of days for each ID, try this: tt = 1686×1 timetable Date ID ___________...

alrededor de 2 meses ago | 0

Answered
Separate hourly data into different days based on the hour and minute time.
What's called for here is a nice mix of old and new. The new is datetimes and durations, the old is finding the day boundaries u...

alrededor de 2 meses ago | 0

Answered
I want to write a program that takes utc time from the user and converts it to gps time.r case letter
This sounds a lot like a homework problem. You may find some help here https://www.mathworks.com/matlabcentral/answers/660293-g...

alrededor de 2 meses ago | 0

| accepted

Answered
Replacing Negative Values in Table with Previous Value in Column
Stef, as near as I can tell, the only thing wrong with your original solution is that D and E are in T, not in the workspace. Th...

alrededor de 2 meses ago | 0

Answered
How to overload the @tabular.unstack method?
David, if you "own" your MATLAB installation, there's nothing preventing you from directly modifying unstack. What I'd suggest,...

alrededor de 2 meses ago | 0

Answered
generate heat map based on lat/lon and data value
The heatmap function accepts a table as input, this should be a one-liner. If you are looking for a surface plot, KSSV's answer ...

alrededor de 2 meses ago | 0

Answered
Subset timetable by specific time windows/periods
This post is more than a year old, but I'm responding in hopes that it might help anyone who looks at this. First, I don't unde...

5 meses ago | 0

Answered
ismember: Find matching entries in table columns (and add entry from matching row)
This is a one-liner with tables: >> A = table([1;3;5]) A = 3×1 table Var1 ____ 1 3 5 >> ...

5 meses ago | 0

| accepted

Answered
Using index to match rows of table
Lukas, you don't say what you actually need to do after getting those rows, but I'm going to suggest that you should be using ro...

5 meses ago | 0

Answered
How to Create txt output from multiselect file by using readtable?
This code DATE = T{:,1}; TIME = T{:,2}; TIME.Format = 'hh:mm:ss'; DOH = T{:,3}; ...

5 meses ago | 0

Load more