John
John

Reputation: 1947

Troublesome package creating

I have some problems with creating package, can you please spot my mistake?

I followed instruction below :

1.Create functions I want in my package

2.Open new project -> R package

3.Create as many R documentation as many functions I implemented, and then put them into man folder

4.Press Ctr+Shift+B to install package.

The warning I'm facing is

Warning: C:/Program Files/R/R-3.6.3/library/mypackage/man/myfun2.Rd:62: All text must be in a section

I search internet about solution to that problem but I found only involved instructions containing other approach. Is there possibility how to fix this ? Or other approach with using other packages is crucial (as roxygen).

Thanks in advance

Upvotes: 0

Views: 61

Answers (1)

Keith McNulty
Keith McNulty

Reputation: 972

You should not write the manual pages yourself. You should use roxygen code to write the manual elements in your function R files, then use devtools::document() to generate the manual pages. See here for examples: https://keithmcnulty.github.io/r_package_training/index.html#1

Upvotes: 1

Related Questions