search for: custreceiver

Displaying 1 result from an estimated 1 matches for "custreceiver".

2006 May 04
0
Eliminating For Loop in Comparison and Replacement
...ailTimes(Time Equipment Failed). The for loop below is part of a larger Monte Carlo simulation involving the reliability of equipment and customers. for (i in 1:length(Fails$CustID)){ j<-1 while (j <= length(Refurb$CustID)){ if (Refurb$FailTimes[j] < Fails$FailTimes[i]){ CustReceiver<-c(CustReceiver,Fails$CustID[i]) PrintDonor<-c(PrintDonor,Refurb$EquipID[j]) Refurb<-Refurb[j!=1:length(Refurb$EquipID),] j<-1 } j<-j+1 } } What this loop does is compare the Fails dataframe to the Refurb dataframe and if the fa...