[Limdep Nlogit List] Help with Matrix command Rndm

Steven Yen syen at utk.edu
Fri Apr 2 07:18:08 EST 2010


Hi
I tried two ways to draw from the bivariate normal. Neither worked. 
Limdep did not seem to recognize "Rmn". Here's the error message:

--> create  ;a=Rmn(muA,sigmaA) $
   Error   768: Have been unable to break down the command segment.
   Error   623: Check for error in RMNaa
   Error   623: Look for: Unknown names, pairs of operators, e.g., */
   Error    61: Compilation error in CREATE. See previous diagnostic.

Any clues? Thanks.

Steven Yen

---

read    ;nobs=5 ;nvar=2 ;names=y,x $
          1 1
          1 2
          2 3
          2 4
          4 5
regr    ;lhs=y ;rhs=one,x ;quiet $
matrix  ;list ;muA=b ;sigmaA=varb $
create  ;a=Rmn(muA,sigmaA) $

MATRIX  ;muA = [10.0, 20.0] $
MATRIX  ;sigmaA = [9.0, 5.0 / 5.0, 16.0] $
create  ;a=Rmn(muA,sigmaA) $

At 07:47 AM 3/22/2010, you wrote:
>Shelton. Use
>CREATE ; A = RMN(mua,sigmaa) $
>You do not need the ROWS command.
>Regards,
>/Bill
>
>----- Original Message -----
>From: "Shelton Schmidt" <schmidts at union.edu>
>To: limdep at limdep.itls.usyd.edu.au
>Sent: Monday, March 22, 2010 1:45:00 AM GMT -05:00 Colombia
>Subject: [Limdep Nlogit List] Help with Matrix command Rndm
>
>I am trying to generate 1000 observations on each of two pseudo-random
>variables, say x1 and x2.  The requirements are as follows:
>
>1.      the bivariate pdf is multivariate normal;
>
>2.      the mean of x1 is 10 and the mean of x2 is 20;
>
>3.      the variance of x1 is 9 and the variance of x2 is 16; and
>
>4.      the covariance between x1 and x2 is 5.
>
>It seems to me that I should be able generate these 2000 numbers using
>the following LIMDEP commands,, but I can't.  Please help.
>
>Thanks,
>Shelton
>
>/***********************************************************************
>*/
>
>RESET $
>
>
>
>MATRIX      ; muA = [10.0, 20.0] $
>
>MATRIX      ; sigmaA = [9.0, 5.0 / 5.0, 16.0] $
>
>
>
>ROWS        ;1000$
>
>SAMPLE      ;1-1000$
>
>
>
>CALC        ; Ran(12345) $
>
>MATRIX      ; A = Rndm(muA, sigmaA) $
>
>/***********************************************************************
>*/
>
>
>
>_______________________________________________
>Limdep site list
>Limdep at limdep.itls.usyd.edu.au
>http://limdep.itls.usyd.edu.au
>_______________________________________________
>Limdep site list
>Limdep at limdep.itls.usyd.edu.au
>http://limdep.itls.usyd.edu.au


Steven T. Yen
http://web.utk.edu/~syen/
Check out our postdoc opening at:
http://web.utk.edu/~syen/postdoc.html


More information about the Limdep mailing list