What am I doing wrong with this function?

I have the following code:
data = textread('new_data.txt');
D = sortrows(data,[11 7], {'ascend' 'descend'});
I get the following error:
Error using sortrows
Too many input arguments.
Error in Cross_Correlation (line 76)
D = sortrows(data,[11 7], {'ascend' 'descend'});
What am I doing wrong?

 Akzeptierte Antwort

Star Strider
Star Strider am 13 Jun. 2016
Bearbeitet: Star Strider am 13 Jun. 2016

2 Stimmen

Maybe this is what you intend:
D = sortrows(data, [11 -7]);

3 Kommentare

Sandy
Sandy am 13 Jun. 2016
Yes! Thank you!
Star Strider
Star Strider am 13 Jun. 2016
My pleasure!
CHLA_SAIC
CHLA_SAIC am 6 Sep. 2017
That worked nicely, thank you.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Tags

Gefragt:

am 13 Jun. 2016

Kommentiert:

am 6 Sep. 2017

Community Treasure Hunt

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

Start Hunting!

Translated by