extendr / rextendr

An R package that helps scaffolding extendr-enabled packages or compiling Rust code dynamically
https://extendr.github.io/rextendr/
Other
196 stars 28 forks source link

Add a vignette of creating an R package #116

Closed yutannihilation closed 3 years ago

yutannihilation commented 3 years ago

Fix #74

Simple version of my blog post, https://yutani.rbind.io/post/2021-06-06-unofficial-introduction-to-extendr-1-your-first-r-package-with-rust/. I guess the original one is a bit too casual to turn into the vignette, so I tweaked a bit.

Note that I turned all R chunk to static with pre-executed results pasted. Of course I can create R package on the tempdir and generate the output lively, I'm a bit afraid it becomes a problem on CRAN check.

Ilia-Kosenkov commented 3 years ago

Overall this looks good. However, the language needs a little bit of polishing. I'd say, a review by a native speaker or someone living long enough in the English-speaking environment would be good.

I also suggest to make separate PRs for runtime Rust code execution (using rust_function, etc.) and for markdown, i.e. what to write in the .Rmd to get access to Rust, similar to what is written in the README.Rmd.

yutannihilation commented 3 years ago

I'd say, a review by a native speaker or someone living long enough in the English-speaking environment would be good.

I agree. My English is not good enough for writing documents like this.

i.e. what to write in the .Rmd to get access to Rust

Isn't rmarkdown.Rmd the one for this (though it doesn't refer to functions like rust_function())?

yutannihilation commented 3 years ago

Thank you for the thorough review! I reflected the comments.

clauswilke commented 3 years ago

Looks good to me. Please go ahead and merge whenever you're ready.

yutannihilation commented 3 years ago

Thanks, I'll keep this open for a while to proofread this once again, and then merge.

clauswilke commented 3 years ago

I think we shouldn't let minor stylistic issues get in the way of producing useful content. It's good enough as is, and I'd suggest you just go ahead and merge. I can do an additional round of copy-editing afterwards also.

yutannihilation commented 3 years ago

Thanks, I'm merging this.