Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Random number function
Replies: 1   Last Post: Sep 11, 2013 8:32 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
John Dickson

Posts: 19
Registered: 10/30/11
Random number function
Posted: Sep 11, 2013 7:20 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

I tried to create a function to create random numbers and them put them in a matrix form. its is giving me "Output argument "new" (and maybe others) not assigned during call to" error. Anyone please help me what is going on?

function new = Random_generate(j)

r1to16 = -1 + (2).*rand(j,48);
r17 = 575 + (100).*rand(j,1);

unifrun =[r1to16 r17]

xlswrite('Random.xlsx', unifrun);

i tried to call the function using "new=Random_number_generate(10);" to generate 10 set of random numbers, didn't help.



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.