Displaying 1 result from an estimated 1 matches for "phdresearcherinstitut".
Did you mean:
phdresearcherinstitute
2007 Dec 15
1
modify a data.frame within a function
...ithin the function.
removedata<-function(datafull,var.removed)
{
attach(datafull)
NArandom<-rnorm(n=length(var.removed), mean=0, sd=1)
for (i in 1:length(var.removed))
if(NArandom[i]>0)
var.removed[i]<-"NA"
datamiss<<-datafull
detach(datafull)
}
-- Yuval Sapir, PhDResearcherInstitute of Evolution, Haifa UniversityHaifa, Israel 3190
[[alternative HTML version deleted]]