-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
plot.time_series in timeSeries.R: Extending functionality for plotting #1
Comments
Thanks for your suggestions! I’ll probably formally open the repository to pull requests with version >= 0.6.0. For now, I’d appreciate it if you’d email me your code. It’d helpful to see how you approached the problem. |
Here’s the code, plus the command I used to produce the .pdf
plot(timeSeries(),type="h",frame.plot=FALSE,pump.handle=FALSE,
main="Deaths from Cholera, each day in 1854",lwd=2,statistic = "deaths",
cex.main=1.75, cex.axis=1.75, cex.lab=1.75)
…___________________
Thomas Coleman
203-252-4897 (mobile)
Risk books: http://closemountain.com/risk-management-books/ <http://closemountain.com/risk-management-books/>
On Jul 27, 2018, at 7:42 PM, lindbrook ***@***.***> wrote:
Thanks for your suggestions!
I’ll probably formally open the repository to pull requests with version >= 0.6.0. For now, I’d appreciate it if you’d email me your code. It’d helpful to see how you approached the problem.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <#1 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AcSuAwTcoV7k2A4jXu3VnxOFknLxuh31ks5uK6VOgaJpZM4Vj5M1>.
|
Your code should now work. You should be able pass most if not all the graphical arguments. Two caveats:
install.packages("devtools") And then: devtools::install_github("lindbrook/cholera", build_vignettes = TRUE) The changes will be on CRAN in version 0.5.1, but that won't be posted till mid-August.
plot(timeSeries(), type = "h", bty = "n", pump.handle = FALSE, |
Peter,
If you are interested, I have posted on SSRN a paper about Snow that uses (and I hope properly credits) your application
“Causality in the Time of Cholera: John Snow as a Prototype for Causal Inference”
https://ssrn.com/abstract=3262234 <https://ssrn.com/abstract=3262234>
…______________________
Thomas Coleman
Lecturer
University of Chicago Harris School of Public Policy
203-252-4897 (mobile)
Risk books: http://closemountain.com/risk-management-books/ <http://closemountain.com/risk-management-books/>
On Jul 28, 2018, at 12:16 AM, lindbrook ***@***.***> wrote:
Your code should now work. You should be able pass most if not all the graphical arguments. Two caveats:
You'll need to install 'cholera' version 0.5.0.9005, which is on GitHub. You may need to install the 'devtools' package:
install.packages("devtools")
And then:
devtools::install_github("lindbrook/cholera", build_vignettes = TRUE)
The changes will be on CRAN in version 0.5.1, but that won't be posted till mid-August.
To get rid of the box around the plot, use bty = "n" (box type) instead of frame.plot = FALSE:
plot(timeSeries(), type = "h", bty = "n", pump.handle = FALSE,
main = "Death from Cholera, each day in 1854", lwd = 2, statistic = "deaths",
cex.main = 1.75, cex.axis = 1.75, cex.lab = 1.75)
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <#1 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AcSuAw1CNNbmmxkn_weXyabi1OwduipWks5uK_OqgaJpZM4Vj5M1>.
|
For what it's worth, there's an R function for that: citation("pkg") |
I have a suggestion for slightly extending the functionality of plot.time_series, to allow passing of more arguments: "type", "lwd", "frame.plot", and "main". The reason is wanting to plot the time-series closer to the graphics of Tufte - something like the attached
SnowBroadTimeSeries.pdf
Would you be amenable to my sending you the changed code (so you can review) or my initiating a pull request?
Thomas
The text was updated successfully, but these errors were encountered: