I was able to hack the code in the polspline package in order to change the plot.polymars function so that I can set the limits of my y-axis. However, I was only able to do this by entering plot.polymars in R, copying the code to Word, changing what I needed, and then pasting the new code in R to redefine the polt.polymars function. I was able to successfully change the function, but now I would like to be able to insert this changed code into the polspline package so that I can use it with python. Is there any easy way to just copy and paste my hacked code in or do I need to go through a more complicated process? Sorry if this is a bit unclear--I'm not yet familiar with R-jargon so let me know if you have any questions. Thanks, Ryan -------------------------------------------------------- Please open the following attachment for important information regarding this e-mail communication. -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: Blackstone Disclaimer.txt Url: https://stat.ethz.ch/pipermail/r-help/attachments/20080306/340fd18c/attachment.txt
Changing code within a package
2 messages · Shewcraft, Ryan, Duncan Murdoch
On 3/6/2008 3:57 PM, Shewcraft, Ryan wrote:
I was able to hack the code in the polspline package in order to change the plot.polymars function so that I can set the limits of my y-axis. However, I was only able to do this by entering plot.polymars in R, copying the code to Word, changing what I needed, and then pasting the new code in R to redefine the polt.polymars function. I was able to successfully change the function, but now I would like to be able to insert this changed code into the polspline package so that I can use it with python. Is there any easy way to just copy and paste my hacked code in or do I need to go through a more complicated process? Sorry if this is a bit unclear--I'm not yet familiar with R-jargon so let me know if you have any questions.
What you should do is download the source of package, and make your changes there. Then run R CMD INSTALL to install it. It would also be polite to mention your changes to the package author and/or maintainer; they might incorporate them into the next release of it. Duncan Murdoch