Set 'n' value by making matlab automatically calculate from a matrix

I have a matrix of XXXXXx1 and i want matlab to automtically calculate an even division of it and set it as a new value.
eg: i have a matrix of 10000x1 and i want matlab to divide it by a fixed number (eg 400) and give me the return value of n=25.

5 Comments

that is not giving me the value i want. its just dividing y/fixed value and giving me that output.
I do not understand the question. Please clarify it.
If A contains your vector of size 10000x1 and fixed is 400, then my line of code results in n being set to 25. If that is not what you mean, you should describe what it is you mean, preferably showing the code you tried.
Do you want to take 25 subsamples of the original vector? Again, please clarify.

Sign in to comment.

Answers (0)

Categories

Find more on Elementary Math in Help Center and File Exchange

Asked:

on 19 May 2018

Commented:

on 12 Jun 2018

Community Treasure Hunt

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

Start Hunting!