Skip to content
Prev 144941 / 398500 Next

Converting Data Types

Edward

Are you sure mymatrix is, in fact, a matrix and note a dataframe (which
is a list)?  I get:
[1] FALSE
[1] TRUE
Error in dgamma(x, shape, scale, log) : 
  Non-numeric argument to mathematical function

That is, the same error as you when mymatrix is a dataframe.  But
convert it to a matrix and:
[1] TRUE
[1] FALSE
V1         V2         V3         V4         V5         V6 
 -99.25657  -84.01700 -237.40735 -201.26922 -170.53122 -159.29770 

HTH ....

Peter Alspach
The contents of this e-mail are privileged and/or confidential to the named
 recipient and are not to be used by any other person and/or organisation.
 If you have received this e-mail in error, please notify the sender and delete
 all material pertaining to this e-mail.