Re: [R] Toronto CRAN mirror 403 error?

2015-05-30 Thread Mark Drummond
I am using another mirror. Just being a good net.citizen.

On Fri, May 29, 2015 at 11:03 PM, Jeff Newmiller jdnew...@dcn.davis.ca.us
wrote:

 This is why there are mirrors. You don't have to wait for them or tell
 them to do their jobs.
 ---
 Jeff NewmillerThe .   .  Go Live...
 DCN:jdnew...@dcn.davis.ca.usBasics: ##.#.   ##.#.  Live
 Go...
   Live:   OO#.. Dead: OO#..  Playing
 Research Engineer (Solar/BatteriesO.O#.   #.O#.  with
 /Software/Embedded Controllers)   .OO#.   .OO#.  rocks...1k
 ---
 Sent from my phone. Please excuse my brevity.

 On May 29, 2015 7:12:56 PM PDT, Mark Drummond m...@markdrummond.ca
 wrote:
 I've been getting a 403 when I try pulling from the Toronto CRAN mirror
 today.
 
 http://cran.utstat.utoronto.ca/
 
 Is there a contact list for mirror managers?




-- 
Cheers, Mark

*Mark Drummond*
m...@markdrummond.ca

When I get sad, I stop being sad and be Awesome instead. TRUE STORY.

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.


Re: [R] Toronto CRAN mirror 403 error?

2015-05-30 Thread Mark Drummond
 It's possible that the mirror manager is unaware of this, and might like
 to be informed.  I know him, and will send an email.

 Duncan Murdoch

Thanks Duncan.


-- 
Cheers, Mark

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.


[R] Toronto CRAN mirror 403 error?

2015-05-29 Thread Mark Drummond
I've been getting a 403 when I try pulling from the Toronto CRAN mirror
today.

http://cran.utstat.utoronto.ca/

Is there a contact list for mirror managers?

-- 
Cheers, Mark

*Mark Drummond*
m...@markdrummond.ca

When I get sad, I stop being sad and be Awesome instead. TRUE STORY.

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.


[R] knittr: non-numeric argument to binary operator

2015-04-26 Thread Mark Drummond
knittr is giving me the above error. The code it is failing on is
multiplying two numeric features of a data frame. I can run the code
by hand and it works fine, but when I try to knit my document, knittr
chokes on the same line.

When kitting:

Quitting from lines 161-175 (RepData_PeerAssessment2.Rmd)
Error in storm_data$PROPDMG * storm_data$property_damage_cost_factor :
  non-numeric argument to binary operator
Calls: Anonymous ... handle - withCallingHandlers - withVisible -
eval - eval
Execution halted

Running the same lines manually (CTRL+Enter) from the .Rmd file:

 storm_data$total_damage -
+ (storm_data$PROPDMG * storm_data$property_damage_cost_factor) +
+ (storm_data$CROPDMG * storm_data$crop_damage_cost_factor)
 str(storm_data$total_damage)
 num [1:902297] 25 2.5 25 2.5 2.5 2.5 2.5 2.5 25 25 ...


Call me baffled. Any pointers are greatly appreciated at this point.

-- 
Cheers, Mark

Mark Drummond
m...@markdrummond.ca

When I get sad, I stop being sad and be Awesome instead. TRUE STORY.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.


Re: [R] knittr: non-numeric argument to binary operator

2015-04-26 Thread Mark Drummond
Thanks all for the responses. As Murphy would have it, after posting
my query I found the problem. I had a function defined that did some
value mapping and I had a stray line of code in the function. Actually
a legitimate line of code that was just in the wrong place.

Cheers,
Mark


On Sun, Apr 26, 2015 at 5:39 PM, Jeff Newmiller
jdnew...@dcn.davis.ca.us wrote:
 Not reproducible [1], so any response likely to be a guess. However, you 
 likely have not put everything that is in your interactive environment into 
 the knitr document, so you are not working with the same data in those two 
 environments.

 [1] 
 http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example
 ---
 Jeff NewmillerThe .   .  Go Live...
 DCN:jdnew...@dcn.davis.ca.usBasics: ##.#.   ##.#.  Live Go...
   Live:   OO#.. Dead: OO#..  Playing
 Research Engineer (Solar/BatteriesO.O#.   #.O#.  with
 /Software/Embedded Controllers)   .OO#.   .OO#.  rocks...1k
 ---
 Sent from my phone. Please excuse my brevity.

 On April 26, 2015 1:41:32 PM PDT, Mark Drummond m...@markdrummond.ca wrote:
knittr is giving me the above error. The code it is failing on is
multiplying two numeric features of a data frame. I can run the code
by hand and it works fine, but when I try to knit my document, knittr
chokes on the same line.

When kitting:

Quitting from lines 161-175 (RepData_PeerAssessment2.Rmd)
Error in storm_data$PROPDMG * storm_data$property_damage_cost_factor :
  non-numeric argument to binary operator
Calls: Anonymous ... handle - withCallingHandlers - withVisible -
eval - eval
Execution halted

Running the same lines manually (CTRL+Enter) from the .Rmd file:

 storm_data$total_damage -
+ (storm_data$PROPDMG * storm_data$property_damage_cost_factor) +
+ (storm_data$CROPDMG * storm_data$crop_damage_cost_factor)
 str(storm_data$total_damage)
 num [1:902297] 25 2.5 25 2.5 2.5 2.5 2.5 2.5 25 25 ...


Call me baffled. Any pointers are greatly appreciated at this point.




-- 
Cheers, Mark

Mark Drummond
m...@markdrummond.ca

When I get sad, I stop being sad and be Awesome instead. TRUE STORY.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.


[R] Predictions on training set shorter than training set

2015-04-23 Thread Mark Drummond
Hi all,

Given a simple logistic regression on a training data set using glm,
the number of predicted values is less than the number of observations
in the training set:

 fit.train.pred - predict(fit, type = response)
 nrow(train)
[1] 62660
 length(fit.train.pred)
[1] 58152


As a relative newcomer, I've run lots of simple glm, CART etc. models
but this is the first time I have seen this happen.

Is this a common issue and is there a fix? An option to predict() perhaps?

-- 
Cheers, Mark

Mark Drummond
m...@markdrummond.ca

When I get sad, I stop being sad and be Awesome instead. TRUE STORY.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.