s-news
[Top] [All Lists]

Saving vector betwen function calls in sapply

To: S-News <s-news@lists.biostat.wustl.edu>
Subject: Saving vector betwen function calls in sapply
From: David Parkhurst <parkhurs@imap.iu.edu>
Date: Fri, 27 Jan 2006 17:48:43 -0500
User-agent: Mozilla Thunderbird 1.0.6 (Windows/20050716)
I'm using splus Enterprise Developer Version 7.0.6  for Microsoft Windows

I'd like to call a function many times using sapply, with the result (a short vector) from call k being available to call k+1. The results of the many calls also need to be saved into a matrix (or list?) in the usual way that sapply does.

How do I save the results of one call for use in the next call? I think this has to do with frames, but I've never understood those.

Thanks for any help.

Dave Parkhurst

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