why not use lda{MASS} and it has cv=T option; it does "loo", though.
Or use randomForest.
if you have to use lrm, then the following code might help:
n.fold <- 5 # 5-fold cv
n.sample <- 50 # assumed 50 samples
s <- sample(1:n.fold, size=n.sample, replace=T)
for (i in 1:n.fold){
# create your tr
nitin jindal wrote:
> If validate.lrm does not has this option, do any other function has it.
> I will certainly look into your advice on cross validation. Thnx.
>
> nitin
Not that I know of, but easy to program.
Frank
>
> On 1/21/07, Frank E Harrell Jr <[EMAIL PROTECTED]> wrote:
>> nitin jinda
If validate.lrm does not has this option, do any other function has it.
I will certainly look into your advice on cross validation. Thnx.
nitin
On 1/21/07, Frank E Harrell Jr <[EMAIL PROTECTED]> wrote:
>
> nitin jindal wrote:
> > Hi,
> >
> > I am trying to cross-validate a logistic regression mod
nitin jindal wrote:
> Hi,
>
> I am trying to cross-validate a logistic regression model.
> I am using logistic regression model (lrm) of package Design.
>
> f <- lrm( cy ~ x1 + x2, x=TRUE, y=TRUE)
> val <- validate.lrm(f, method="cross", B=5)
val <- validate(f, ...)# .lrm not needed
>
> My
Hi,
I am trying to cross-validate a logistic regression model.
I am using logistic regression model (lrm) of package Design.
f <- lrm( cy ~ x1 + x2, x=TRUE, y=TRUE)
val <- validate.lrm(f, method="cross", B=5)
My class cy has values 0 and 1.
"val" variable will give me indicators like slope and