How to copy data from one timetable to another
Show older comments
Hi all,
I have three timetables (called Tmin, Tmax, Prec) with daily meteorological variables at two measurement sites (Site 1 and Site 2; I will come back to Site 3 in a moment). The data are from 1st July 2018 to now. Here an example of the Prec timetable:
353×3 timetable
time Site_1 Site_2 Site_3
____________________ ______ ______ ____
01-Jun-2018 00:00:00 0.2 0.2 NaN
02-Jun-2018 00:00:00 0 0 NaN
03-Jun-2018 00:00:00 0 0 NaN
...
I'm trying to add data from a public weather station (Site 3, currently all NaNs) for the same period. These data are available online in monthly csv files which I import in a loop into monthly timetables:
30×3 timetable
Date MinimumTemperature__C_ MaximumTemperature__C_ Rainfall_mm_
__________ ______________________ ______________________ ____________
2018-06-01 4.1 13.3 0
2018-06-02 3.5 13.6 0.2
2018-06-03 4.3 13.8 0
What I'm trying to do is to copy Site 3 data from each monthly timetable into a respective row in column 3 of my main timetables (Tmin, Tmax, Prec).
1) Is there a simple function to do that?
2) Is it a problem that the date format isn't the same? If so, how can I change it?
Many thanks in advance for help!
Accepted Answer
More Answers (0)
Categories
Find more on Timetables in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!