Skip to content

Unable to Plot using headers (converting to Numeric)

3 messages · David Winsemius, Struckmeier, Nathanael

#
I tried command
as.numeric(Qty)    #converting column"Qty" in object "demand" to
numeric. However it remains a non-numeric value. 

What is the best way to convert a column of data to a numeric value in
R?
What is the best way to convert dates into a numeric format (or some
format able to be used in an x,y scatter) while still maintaining its
inherent "date" property? 


StatBat2


-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org]
On Behalf Of Struckmeier, Nathanael
Sent: Friday, May 27, 2011 1:57 PM
To: Bert Gunter
Cc: R-help at r-project.org
Subject: Re: [R] FW: Unable to Plot using headers.
[1] FALSE
[1] FALSE
[1] FALSE

Doesn't look like they are numeric. I'll try and convert them and check
back if I have problems. Thanks Gunter!

Thank You
Nathan Struckmeier 
Supply Chain Planning
Office 541-864-5029
NStruckmeier at HarryandDavid.com
2500 S. Pacific Hwy, Medford OR, 97501
Daily Humor:  Chuck Norris can slam a revolving door....



-----Original Message-----
From: Bert Gunter [mailto:gunter.berton at gene.com] 
Sent: Friday, May 27, 2011 1:47 PM
To: Struckmeier, Nathanael
Cc: R-help at r-project.org
Subject: Re: [R] FW: Unable to Plot using headers.

Are Date and Qty numeric? Check.

-- Bert

On Fri, May 27, 2011 at 1:43 PM, Struckmeier, Nathanael
<NStruckmeier at harryanddavid.com> wrote:
I
quite
should
[mailto:r-help-bounces at r-project.org]
http://www.R-project.org/posting-guide.html

  
    
#
On May 27, 2011, at 5:06 PM, Struckmeier, Nathanael wrote:

            
Right. You didn't assign it to anything. AND since you are apparently  
following the IMO misguided advice to use these as attach()-ed  
variables, even if you did make a change ,,,, it would be lost as soon  
as you detached it. You really do need to read the "Introduction to R"  
and work through the examples. Asking question like this on r-help is  
slowing your progress.
It depends on what it might be. Pay attention to the use of str() as  
you do your reading and "homework".
It depends on what they really are. Are they just characters or are  
they one of hte several DateTime classes? Again... back to the books.
David Winsemius, MD
West Hartford, CT
#
I'll take your advise and go through the intro. Thanks

Thank You
Nathan Struckmeier 
Supply Chain Planning
Office 541-864-5029
NStruckmeier at HarryandDavid.com
2500 S. Pacific Hwy, Medford OR, 97501
Daily Humor:  Chuck Norris can slam a revolving door....



-----Original Message-----
From: David Winsemius [mailto:dwinsemius at comcast.net] 
Sent: Friday, May 27, 2011 2:14 PM
To: Struckmeier, Nathanael
Cc: R-help at r-project.org
Subject: Re: [R] FW: FW: Unable to Plot using headers (converting to
Numeric)
On May 27, 2011, at 5:06 PM, Struckmeier, Nathanael wrote:

            
Right. You didn't assign it to anything. AND since you are apparently  
following the IMO misguided advice to use these as attach()-ed  
variables, even if you did make a change ,,,, it would be lost as soon  
as you detached it. You really do need to read the "Introduction to R"  
and work through the examples. Asking question like this on r-help is  
slowing your progress.
It depends on what it might be. Pay attention to the use of str() as  
you do your reading and "homework".
It depends on what they really are. Are they just characters or are  
they one of hte several DateTime classes? Again... back to the books.
[mailto:r-help-bounces at r-project.org
http://www.R-project.org/posting-guide.html
David Winsemius, MD
West Hartford, CT