Dear all,
The following function code fails with errors (see below):
RegPlots <- function (data, ContrVar, RespVar){
intNmbrRows<-length(RespVar);intNmbrCols<-lenght(ContrVar)
par(mfrow=c(intNmbrRows,intNmbrCols))
For(i in 1:intNmbrRows){
For (j in 1:intNmbrCols){
Am 11.08.2012, 01:18 Uhr, schrieb Rui Barradas :
[...] The solution is obviously to write 'for', with lowercase 'f'.
Hope this helps,
Dear Mr Barradas,
indeed it did help, thank you very much!
Best regards
Holger van Lishaut
__
R-help@r-project.o
Am 11.08.2012, 01:18 Uhr, schrieb Rui Barradas :
[...] The solution is obviously to write 'for', with lowercase 'f'.
Hope this helps,
Dear Mr Barradas,
indeed it did help,
thank you very much!
Best regards
Holger van Lishaut
__
R-help@r-project.o
Dear r-help members,
I have a number in the form of a string, say:
a<-"-01020.909200"
I'd like to extract "1020." as well as ".9092"
Front<-grep(pattern="[1-9]+[0-9]*\\.", value=TRUE, x=a, fixed=FALSE)
End<-grep(pattern="\\.[0-9]*[1-9]+", value=TRUE, x=a, fixed=FALSE)
However, both strings gi
Dear all,
regmatches works.
And, since this has been asked here before:
SignifStellen<-function(x){
strx=as.character(x)
nchar(regmatches(strx, regexpr("[1-9][0-9]*\\.[0-9]*[1-9]",strx)))-1
}
returns the significant figures of a number. Perhaps this can help someone.
Thanks & best reg
Am 22.08.2012, 21:46 Uhr, schrieb Dr. Holger van Lishaut
:
SignifStellen<-function(x){
strx=as.character(x)
nchar(regmatches(strx, regexpr("[1-9][0-9]*\\.[0-9]*[1-9]",strx)))-1
}
returns the significant figures of a number. Perhaps this can help
someone.
Sorry, to
6 matches
Mail list logo