I am trying to generate a sequence of diagonal matrices.

In the scalar case I would use something like, seq(0,100,by=1).

How do I generalise the above for , say a 2 dimensional diagonal matrix. In
other words how do I produce the series of diagonal matrices {
diag(0,2),diag(1,2), diag(2,2),...,diag(100,2)}?

Thanks
Meddee

--
View this message in context: 
http://r.789695.n4.nabble.com/Generating-a-sequence-of-diagonal-matrices-tp3779623p3779623.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to