Azzera filtri
Azzera filtri

i am trying to replace one column with another in dataset?

2 visualizzazioni (ultimi 30 giorni)
Hi all,
I have big dataset matrix that the dates column is corrupted. I success fixing the date in another dataset matrix with only one column. In the big matrix the column is the column i want to replace. The big matrix size : 374x14 the fix column i want to replace in the big matrix is : 374x1
example to line in matalb i wrote for the replace? Load_DATA(:,1) =Date_Fix ; % replaces corrupted dates with corrected dates
error i getting in matlab:
Error using dataset/subsasgnParens (line 133) Subscripted assignment dimension mismatch for dataset variable 'Date'.
Error in dataset/subsasgn (line 79) a = subsasgnParens(a,s,b,creating);
Error in DATA_INPUT (line 24) Load_DATA(:,1) =Date_Fix ; % replaces corrupted dates with corrected dates
Can someone help me to resolve it?

Risposte (1)

Thorsten
Thorsten il 29 Set 2016
Probably the size of your variables are not as descripted. Otherwise it works as expected:
Load_DATA = rand(374, 14);
Date_Fix = rand(374, 1);
Load_DATA = Date_Fix;

Categorie

Scopri di più su Get Started with MATLAB in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by