`osfr` - interface with the OSF from R

Hi everyone,

A few years ago I was e-mailing with Karthik about a package to interface with the Open Science Framework from R. I then got to some work, left it, got back to it, left it for a while and although there is now a reasonable alpha version, there is much improvement left. You can find the Github repo here and a demo I did last november here. It’s not yet on CRAN.

Currently it has basic functionality: upload files, download files, create structures, if I remember correctly move files, so there are some basic things in place.

Karthik recommended opening up a topic here so discussion can take place. Feature requests more than welcome, and I’ll update this post every now and then for an overview.

Cheers,
Chris

Feature requests

[ ] Default the OSF_PAT argument to the environment variable value (thanks @thosjleeper!)
[ ] Documentation at the package level (i.e., ?osfr; thanks @thosjleeper!)
[ ] Adding addons (e.g., Github) to OSF repo (thanks @benmarwick!)

2 Likes

Awesome!

I would be inclined to make the OSF_PAT part an argument to the functions that defaults to the environment variable value. That gives users flexibility about the authorization workflow and is, I think, Hadley’s recommended practice.

I also didn’t see package level docs available from ? osfr (sorry if I missed them), but I find that an important aspect of any package.

Small thing: your copyright year in LICENSE should probably be 2016-2017.

Wow, yes, this is great to see again (I saw the demo last year), thanks for creating that package! Currently I count on my OSF repo mirroring my github repo, which seems to work quite well. But it would be handy to control some of this from R.

Could I request one ‘feature’? Would it be possible to have a minimal readme that demos some of the core functions of the package, from the perspective of a typical project situation? That would be very helpful to see how this can be incorporated into an existing workflow and toolkit. Thanks!

Ben: We should also include OSF as a backend in the recipes I talked about.

1 Like

Thanks for the warm welcome and the suggestions. I updated the feature requests and cross-posted them as github issues to work through.

Cheers,
Chris

1 Like

Hey @chjh, are you planning to work on this again? I want to upload rmarkdown reports straight from R to OSF Wikis (including images), ideally with minimal fuss for users (for my codebooks). I’m assuming this will require tailoring some markdown specifics to what the OSF renders.

1 Like

After discussing about upcoming API changes and urgency, this is now transferred to the COS. Best to check out the GitHub page of the repo and see what they can do for you. :slight_smile:

1 Like