Is there a way to fix errata in Rdocumentation.org? - r

I use R pretty often and I have noticed that while checking any package's documentation at RDocumentation.org, some pages have errata so I'd like to help fix them if possible. I can't find any way to contact the website team. Any ideas?

I believe RDocumentation.org scrapes its information directly from CRAN/GitHub sources of packages, so it makes more sense to try to contact the package maintainers upstream.
Contributed packages
if a package is on GitHub, you can
fork the repository, fix the documentation errors yourself, and submit a pull request
record a GitHub issue (if there is an open issues list)
you might want to check to see if there is a README about contributions to see what the maintainers prefer
if the package is on CRAN, you can go to its CRAN page (e.g. here) and see if there is a development URL or BugReports: field in the description
if all else fails, the maintainer's e-mail is always available via maintainer("pkg_name")
Base packages
If you find documentation errors in packages that are maintained by R-core (unlikely but possible), you should probably start a discussion on the r-devel#r-project.org mailing list. Alternately, you can request write access to the R bug tracker (see here).

Related

Julia adding packages give an "package names could not be resolved" error

In Julia 1.5.3 when i try to add MLPlots package with this command "] add MLPlots" I get the below error :
ERROR: The following package names could not be resolved:
* MLPlots (not found in project, manifest or registry)
Fredrik's comment should really be the answer here, so I'll expand on it a little bit:
When you do ] add SomePackage, Julia's package manager will search the General Registry to look for the package, and then install it. As you will see when looking at the M entry in the general registry, MLPlots is not registered, hence the "not found in ... registry" error you're seeing.
Now it should be noted that packages don't have to be installed in the general registry to be installed - the general registry is just the default registry, and largely a convenience tool in the Julia ecosystem which provides the default location to check for packages and enforces certain standards on registered packages to ensure things play nicely with each other. That being said, nothing prevents you from
Adding a different registry: as noted in the Pkg.jl docs introduction, "it allows multiple registries managed by different parties to interact seamlessly. In particular, this includes private registries which can live behind corporate firewalls. One example of this is the JuliaPro registry, which offers a curated subset of the General registry;
Just adding a package that's not registered anywhere, either from a local path or using a GitHub (or equivalent service, e.g. GitLab) link.
While the second would in principle be an option in this case, at this point the other problem mentioned in Fredrik's comment becomes pertinent:
(#v1.6) pkg> activate --temp
Activating new environment at `/tmp/jl_pKGogE/Project.toml`
(jl_pKGogE) pkg> add https://github.com/JuliaML/MLPlots.jl
Cloning git-repo `https://github.com/JuliaML/MLPlots.jl`
Updating git-repo `https://github.com/JuliaML/MLPlots.jl`
ERROR: could not find project file in package at `https://github.com/JuliaML/MLPlots.jl` maybe `subdir` needs to be specified
Since v1.0, Julia requires packages to come with a "project" file (Project.toml), which specifies the packages dependencies including (at least as best practice, and for packages in the general registry) compatibility bounds. As the package you're looking at was last worked on 5 years ago, it is not in a format that Julia's current package manager can deal with.
Looking at the package itself I would also say that this isn't necessarily a problem - not trying to knock Tom here who's done exceptional and pioneering work in the Julia plotting ecosystem, but this specific package seems to be a bit of a proof-of-concept which doesn't provide an awful lot of functionality. Maybe if you post on the Julia Discourse a bit of a more open-ended request for help with whatever problem you're trying to solve people can point you towards the current state-of-the-art packages in the ecosystem.
I'll just add here that the central package for standard machine learning in Julia at the moment is probably MLJ.jl, which includes a roc_curve function that could give you the basis for the ROCAnalysis plot you see in the MLPlots readme.

Can CRAN packages be modified and re-uploaded by others?

I've been working with R for a long time, but I'm a complete newbie in writing (and/or publishing) own packages via CRAN. Actually, I create a new package for educational purposes (university) and I want to load it to CRAN, so my students (and, of course, others) can download and use it.
After I uploaded my package (let's call it “JohnnyStat”), is it possible that another person (let's call “Mark Miller”) modifies it and adds his name as another “co-author” (“author”/“contributor” etc.)?
So, as a result, the package “JohnnyStat” would be registered as written by “Johnny” AND “Mark Miller”?
No. Only the maintainer can upload package updates, not any co-author. An acceptance mail is automatically sent to the mail address of the maintainer. And no-one can become maintainer without the explicit consent of the previous maintainer (for obvious reasons).
If you want the possibility of various people modifying the package, maybe CRAN is not the best option. It is possible to install from other repositories. Why not have the package at e.g. R-forge or github?
You may get a more complete answer if you ask this on the CRAN mailing list R-package-devel.

Modifying R package maintained by someone else

There's a semantic error in a function of an R package written by someone else. I contacted that person which is mentioned in the 'DESCRIPTION' file of the package over email, and there is no response. But, I need to move forward with my project.
Is it possible for me to correct that error and check-in the change of that project ? If that's not possible, should I write my own version of the function with the correction and call it? What would be the best way to move forward ? Thanks.
The only way to update that particular package on CRAN is to contact the package maintainer. But you can just obtain the package's sources (you can fork it from CRAN readonly mirror on a github), fix it your way and source changed .R files after loading the package (or build entire package from sources if your fixes are in C++ code). I've done it many times. If your changes may be useful to the community, you're encouraged to create your own package.

R how to make my package available online

I have developed a R package, and I want to let anyone uses it by calling
install.packages(my package name)
help?
I tried to search on Google, and I installed some libraries to do that but these libraries make my package corrupted so i thought to ask you maybe you suggest me the best way
i would like if i have my package on github thanks
I think the best thing to do would be to go over to GitHub and do some reading. You mention in the comments that you want the user to be able to use install.packages() and not install_github(). For that you'll need to either submit your package to CRAN or make the tarball source available for download somewhere so that the user can install from source after download.
The CRAN Repository Policy is a good thing to read, as well as Writing R Extentions and of course all the info at GitHub.
By the way, devtools::install_github() is very widely used, so you may want to rethink your stance on only using install.packages() if not submitting to CRAN.
I have developed a R package, and I want to let anyone uses it
by calling
install.packages(my package name)
help?
That is precisely what drat is for. It lets you create a repository and by far
the easiest way is just to let GitHub host it. The package vignettes detail how.
See the drat documentation, or the blog posts about it. Also that we discussed just today in the r-packages-devel list how drat can help as an additional_repostitories even for CRAN packages.

What to do after I've found and fixed some bugs in CRAN package and author is not responding?

I'm not new to R but I'm new to finding errors in CRAN packages which I wish to correct. In my case, I like to upload packages under development on github; then if errors are found people can generate pull requests so they're fixed. Not not everyone chooses to go down this route though.
My question relates to the above - if I find a (substantial) error in a widely used CRAN package (which I need to import in my own package), and I have fixed the errors, what are the steps to take? In particular if
the CRAN package does not have a project page (github etc.) and
the author is not replying to e-mails
Currently my solution is to upload a copy of the 'corrected' package on my github page and instruct people to install that version before using my own. This is cumbersome and not an elegant solution. Are there better alternatives to this?
This the good and the bad of R ... sometimes package are forsaken!
Get the source code and create your own pacakge. If it is useful for you it will be useful for others!
there a lot of documentations on how to create packages:
http://www.r-bloggers.com/create-an-r-package-in-under-6-minutes/

Resources