search for: limstr

Displaying 2 results from an estimated 2 matches for "limstr".

Did you mean: limit
2002 Jan 19
0
SUMMARY: readline() to vector
Thanks to all who answered my question (appended to this message). Two solutions: 1. If the user answers with the 4 lim values (i.e., 10,20,1,100), limStr <- readline("Enter xlim and ylim values: "); lim <- as.numeric(unlist(strsplit(limStr, ","))); 2. If the user answers in R vector notation (i.e., c(10,20,1,100) ) limStr <- readline("Enter xlim and ylim values: ") lim <- eval(parse(text=limStr) Note...
2002 Jan 18
3
readline() to vector
Hi! I'm trying to use readline() to ask for xlim() and ylim() values for a subsequent plot. I'm doing: lim <- readline("Enter xlim and ylim values: ") then would like to use the values in lim for a plot: plot(etc, xlim=lim[1:2],ylim=lim[3:4]) The problem is that lim is a character,i.e., "10,20,-10,50" or "c(10,20,-10,50)" depending on the input to