Effacer les filtres
Effacer les filtres

dividing data into sub-data

1 vue (au cours des 30 derniers jours)
Radim Zapletal
Radim Zapletal le 24 Jan 2019
How can I divide multiple data into 2 submultiple data?
I have those data:
-1 1 1 1
-1 -1 -1 1
-1 1 -1 -1
-1 1 1 -1
-1 1 1 -1

Réponses (1)

Bob Thompson
Bob Thompson le 24 Jan 2019
A = [-1 1 1 1; -1 -1 -1 1; -1 1 -1 -1; -1 1 1 -1; -1 1 1 -1];
B = A(:,1:2);
C = A(:,3:4);
  1 commentaire
Bob Thompson
Bob Thompson le 24 Jan 2019
Creating arrays from portions of a larger array using the index of the larger array will work for most any scenario, you just need to know what kind of indexing you're looking for. If you could elaborate more on what kind of separation you are looking to perform I could give a more comprehensive answer.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Logical dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by