x is the value you asked for. I think you are confusing its printed representation with its value. Try cat(x) and strsplit(x, "")
On 12/2/06, Shubha Vishwanath Karanth <[EMAIL PROTECTED]> wrote: > But when I do this I need x value to be " C:\Program > Files\R\R-2.4.0\bin\Rgui.exe" and not C:\\Program > Files\\R\\R-2.4.0\\bin\\Rgui.exe" > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Gabor > Grothendieck > Sent: Saturday, December 02, 2006 5:21 PM > To: Shubha Karanth > Cc: [email protected] > Subject: Re: [R] Fwd: Urgent Help in Paste Command > > Try this: > > > x <- readline() > C:\Program Files\R\R-2.4.0\bin\Rgui.exe > > x > [1] "C:\\Program Files\\R\\R-2.4.0\\bin\\Rgui.exe" > > > > You can also use > > readLines("clipboard") > > if you are trying to read in something from the clipboard. > > > On 12/2/06, Shubha Karanth <[EMAIL PROTECTED]> wrote: > > Hi Experts, > > > > I want to see my object as below: > > 'C:\Program Files\R\R-2.4.0\bin\Rgui.exe' > > So I use the paste command. None of the below is working. Could anyone > help > > me on this? > > > > > paste("'C:\Program Files\R\R-2.4.0\bin\Rgui.exe'") > > [1] "'C:Program FilesRR-2.4.0\binRgui.exe'" > > > > > paste("'C:","\","Program > Files","\","R","\","R-2.4.0","\","bin","\"," > > Rgui.exe'",sep="") > > Error: syntax error in "paste("'C:","\","Program" > > > > >paste("'C:","Program Files","R","R-2.4.0","bin","Rgui.exe'",sep="\") > > + > > > > I need to only use the \ symbol and not / or \\. Please help me... > > > > Thank you, > > Shubha. > > > > [[alternative HTML version deleted]] > > > > > > > > ______________________________________________ > > [email protected] mailing list > > https://stat.ethz.ch/mailman/listinfo/r-help > > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > > and provide commented, minimal, self-contained, reproducible code. > > > > > > > > ______________________________________________ > [email protected] mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > ______________________________________________ [email protected] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
