Gotta love R.

Thanks to Bill Dunlap, Peter Langfelder and Jim Holtman for no less than 3 different solutions.

JN


On 12-03-01 04:25 PM, Peter Langfelder wrote:
pstr<-c("b1=200", "b2=50", "b3=0.3")

split = sapply(strsplit(pstr, split = "="), I);

pnum = as.numeric(split[2, ]);
names(pnum) = split[1, ];


______________________________________________
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