s-news
[Top] [All Lists]

Inconsistent behavior in BATCH mode

To: <s-news@lists.biostat.wustl.edu>
Subject: Inconsistent behavior in BATCH mode
From: "Michel Guillet" <guillet@creascience.com>
Date: Thu, 7 Aug 2003 10:08:34 -0400
Importance: Normal
Organization: Creascience
Reply-to: <guillet@creascience.com>

Dear all,

I have encountered what seems to me a very strange behavior of S-Plus batch mode:

I have a script that estimates a model with the nlsList function, then extracts the parameters and puts them in a data frame

my.coef <- as.data.frame(coef(nlsList(…)))

It then tests for the existence of a given coefficient to impute a value if missing and perform another action otherwise:

if (is.na(my.coef[1,1])) … else …

When running this from within S-Plus, everything works smoothly.

However, when this script is submitted in batch mode, is.na(my.coef[1,1]) returns a NULL value. I have checked that my.coef[1,1] actually gets a value in batch mode.

 

Has anyone an idea on what might be causing this?

 

Thanks in advance,

Michel

 

___________________________________________

 

Michel Guillet

President

Creascience

1097, Saint-Alexandre Suite 301

Montreal QC

H2Z 1P8 Canada

Tel: (514) 840-9220 x26

Web site: www.creascience.com

The Virtual Statistician: www.virtualstatistician.com

Statistical Training: training.creascience.com

___________________________________________

 

<Prev in Thread] Current Thread [Next in Thread>