similar to: For Loop help needed

Displaying 20 results from an estimated 10000 matches similar to: "For Loop help needed"

2005 Sep 15
2
R: deleting rows
hi all hopefully some one can help. assume that i imported the following data into R (say the data frame is called a) x1 x2 x3 1 NA 3 1 2 NA 1 2 3 3 NA 6 4 5 9 7 5 6 7 8 9 NA 7 9 How can i construct a new data frame that only contains those rows that does not contain the NA's? is these a quick way? ie x1 x2 x3 1 2 3 4 5 9 7 5 6 7 8 9 in this example we can simple use
2005 Feb 24
4
r: functions
hi all i have a function that uses two inputs, say xdata and ydata. An example is the following, simple1<-function(xdata,ydata) { ofit<-lm(ydata~xdata) list(ofit) } say i use arbitray number for xdata and ydata such that D = x1 x2 y 1 1 10 2 6 6 3 10 7 x<-D[,1:2] and y<-D[,3] if one uses these inputs and rund the program we get the following: >simple(xdata=x,ydata=y)
2005 Dec 31
1
r: RODBC QUESTION
hello all i have a quick question. i have been using the RODBC library (trying to read Excel data into R but i am doing this by using Rexcel. this is probably not the correct forum - sorry for this). my code is shown below: Sub A() 'start the connection to R Call RInterface.StartRServer RInterface.RRun "library(RODBC)" RInterface.RRun "A =
2009 Oct 12
2
add=TRUE function not working
Hey everybody, I have a matrix with three columns. I want to plot two columns (independent variable) against one column (the defendant). This is my code and the error associated with it: plot(p, q, data=columns) > plot(pprime,q, add=TRUE) Warning messages: 1: In plot.window(...) : "add" is not a graphical parameter 2: In plot.xy(xy, type, ...) : "add" is not a graphical
2002 Mar 07
8
linear correlation?
Whether the two variables have the same units does not matter. Moreover, even if there were some way of converting cm to kg the correlation would still be the same because the correlation is invariant under unit conversion as it is invariant under multiplication of its arguments by a constant. As for your second question, the correlation estimator is a continuous function of each of the
2012 Jun 19
1
CentOS 6.2 on partitionable mdadm RAID1 (md_d0) - kernel panic with either disk not present
Environment: CentOS 6.2 amd64 (min. server install) 2 virtual hard disks of 10GB each Linux KVM Following the instructions on CentOS Wiki <http://wiki.centos.org/HowTos/Install_On_Partitionable_RAID1> I installed a min. server in Linux KVM setup (script shown below) <script> #!/bin/bash nic_mac_addr0=00:07:43:53:2b:bb kvm \ -vga std \ -m 1024 \ -cpu core2duo \ -smp 2,cores=2 \
2008 Oct 29
1
Help with impute.knn
ear all, This is my first time using this listserv and I am seeking help from the expert. OK, here is my question, I am trying to use impute.knn function in impute library and when I tested the sample code, I got the error as followingt: Here is the sample code: library(impute) data(khanmiss) khan.expr <- khanmiss[-1, -(1:2)] ## ## First example ## if(exists(".Random.seed"))
2008 Jul 07
3
rsh problems in CentOS 5.2 (was "cvs command failure on 5.2")
Okay, I've narrowed the problem down quite a bit. As previously reported, in CentOS 5.2 I get this: $ cvs log Makefile poll: protocol failure in circuit setup cvs [log aborted]: end of file from server (consult above messages if any) Turns out this is a problem with rsh: $ rsh khan ls connect to address 10.24.15.48 port 544: Connection refused Trying krb4 rsh... connect to address
2014 Oct 15
2
[LLVMdev] using -debug-ir to map identify IR mapping
Adding the flags in an opt pass seems to do the trick. I added the flags as follows M.addModuleFlag(llvm::Module::Warning, "Dwarf Version", 3); M.addModuleFlag(llvm::Module::Error, "Debug Info Version", llvm::DEBUG_METADATA_VERSION); llvm-dwarfdump and addr2line now point at a line in .ll files, not the source files. Thanks! /Muneeb On 15 Oct
2014 Oct 15
2
[LLVMdev] using -debug-ir to map identify IR mapping
Yes, I am using opt and llc from the same version (3.5). I know that there were issues with debug-ir in 3.4. I have explored the source tree myself for 3.5 and I know that the pass -debug-ir does kick in with opt. But I have no clue of what happens with the debug information in (and after) the llc pass. /Muneeb On 15 Oct 2014, at 17:14, David Blaikie <dblaikie at gmail.com> wrote: >
2005 Mar 04
11
R: simulation
hi all a simple question i want to run simulations in r. i however want the experiments to be repeated at a later time with exactly the same numbers by other users. can i set the random number seed for rnorm in some way? e.g. is there some arguement that goes with rnorm? please supply an example regards Allan
2010 Jan 22
4
facter question
int he example below I run facter looking for the fact "sp_serial_number". as you can see, the command facter sp_serial_number returns nothing, but the fact is there and is returned when just running facter and grepping for the fact. Some fact seem to work and others do not. any ideas? marcuspro:~ allan$ facter --version 1.5.7 marcuspro:~ allan$ facter sp_serial_number marcuspro:~
2010 Sep 15
3
Skip Busy Agents/Channels from Queue
Is there a way skip / ignore the member whose status is busy in the Queue. I have two channel member in queue and i have set the peer limit 2 for these members. I want to skip those member who are currently on the call (answered to calls) and now their status is busy, if Queue see the busy status caller will not enter in the Queue and go to the next priority. [test-queue] strategy = rrmemory
2005 Jul 29
5
R: graphics devices
a simple question how does one produce plots on two different graphics devices? / allan
2004 Feb 03
3
R: plotting multiple functions
Hi all Another simple question. I would like to plot three graphs one the same plot with different colours. Say red, blue and black. Here are the functions. r1<-1+5*cos(2*pi*seq(1:100)/20)+rnorm(100) r2<-1+7*sin(2*pi*seq(1:100)/20)+rnorm(100) r3<-1+7*sin(2*pi*seq(1:100)/20)+5*cos(2*pi*seq(1:100)/20)+rnorm(100) Regards Allan
2009 Jun 04
3
WWDC Puppeteer lunch
Reminder for Mac Puppeteers going to WWDC How about we meet for lunch at noon on Tuesday. Let''s try to get the table closet to the Odwalla refrigerator, just for reference. We can get more specific on this list on the 8th after we verify the set up. I might even get there a little earlier and put down "reserved" tags. --- Thank you, Allan Marcus Solutions Architect Central
2007 Dec 12
1
APARCH
Hi, Could somebody say if it is possible to compute APARCH-models with garchFit commands. I have earlier used aaa (garchOxFit) and now I try to use bbb (look below) aaa <- garchOxFit(formula.mean=~arma(1,0),formula.var=~aparch(1,1),series=nyk,cond.dist=c('gaussian')) bbb <- garchFit(formula=~arma(1,0)+aparch(1,1),data=nyk) aaa works well, but I need other characteristics of
2014 Oct 15
2
[LLVMdev] using -debug-ir to map identify IR mapping
On Wed, Oct 15, 2014 at 9:04 AM, Adrian Prantl <aprantl at apple.com> wrote: > I have no experience with debug-ir, but is it possible that the debug-ir > pass never sets the debug info version? There should be a named metadata > node > !llvm.module.flags = !{..., !123} > !123 = metadata !{i32 1, metadata !"Debug Info Version", i32 2} > in the .ll output. If
2009 Jul 31
5
Creating a column based on data in another column
hello all, I have a data frame and I want to create a column which assigns a letter based upon the value in another column. The data column has velocities ranging from 0 to 1000. So for example, for velocities between 0 and 300 I'd like to assign the letter "A" in the new column, for 300-600, "B" and so on and so forth. How would I do this? Thank you very much! Mehdi
2004 Feb 10
6
R: lags
hi all how does one simulate a random walk process? i.e y(0)=0 y(t)=y(t-1)+ e(t) where e(t) is normal(0,1) say. Regards allan