Skip to content
This repository has been archived by the owner on Jul 23, 2023. It is now read-only.

Document changes #29

Open
ErvanCH opened this issue Oct 23, 2018 · 5 comments
Open

Document changes #29

ErvanCH opened this issue Oct 23, 2018 · 5 comments

Comments

@ErvanCH
Copy link
Collaborator

ErvanCH commented Oct 23, 2018

Hi Mauro,

Thanks for your help. I am working in background to fix/update/examplify the functions. While running my code again for my paper, I got a strange behaviour and I found the problem.
In function "computeAGB" (l, 466-481), you probably cleaned up the following expression

df['Family' == "Arecaceae", "agb" := agbPalm(dbh2)]
by
df["Family" == "Arecaceae", "agb" := agbPalm(dbh2)]

However, data.table doesn't know how to deal with " " and fails to do the job (and messed up my whole analysis).
Shall I kindly ask you to document all changes that you are doing for me to double check, please.
Thanks
Ervan

@maurolepore
Copy link
Contributor

Hi Ervan,

  • I'm very sorry for that. I'm surprised that styler doesn't account for that issue. Maybe we should report it as a bug?

image

  • But how could I get an output then? Can you send me the code that exposed this problem?

  • All changes are documented -- mine and yours. Git takes care of that automatically. To review what I did you need to inspect my commits. Also, I make my best to link each commit message to a relevant issue. For example, notice how my commit is linked to issue 16:

image

  • If you click on the commit message, you'll jump to the actual files that changed and you can inspect them in Split mode. For example, here is the relevant line:

image

@ErvanCH
Copy link
Collaborator Author

ErvanCH commented Oct 23, 2018 via email

@maurolepore
Copy link
Contributor

Git and GitHub

Be kind to yourself and patient. GitHub has great tools for collaboration but it takes a lot of practice to become fluent. You are doing stuff that I think is of advanced level.

I haven't really look for detailed information ...
There is too much information out there. Whenever I get stuck I generally start here: https://help.github.com/.

It might be good if you want to make a short tuto and the very basic of collaborative work through
Git. ... how to:

  • check changes in version,
  • restore or accept corrections.

Sure. I applaud your determination to learn this stuff. We can organize a video-chat, but first I suggest you read these two short resources:

  1. https://guides.github.com/introduction/flow/

Once you are fluent with reviewing pull requests, I can stop working on master branch and instead work on branches dedicated to pull requests. You could even remove my privilege to push into master. Then it'll be up to you to review and merge my pull requests into master. At the beginning this workflow may slow you down. But in the long run it is certainly the way to go.

Packages

Similarly, have the key steps of developing a R package
from scratch would be very useful. From my experience, I got a bit lost and
don't know where to start...

Sure, both of

@maurolepore
Copy link
Contributor

Be kind to yourself. We are doing advanced stuff.

Can you video-chat this week? First please read this two short documents:

  1. https://help.github.com/articles/about-pull-requests/
  2. https://guides.github.com/introduction/flow/

RE: Packages, sure. I'm always happy to talk about building packages. We'll likely need to do this in another meeting. Otherwise it'll be too much stuff to digest.

What I use every time I build a new package is this checklist.

For some background, I remind you of these two resources:

  • Video tutorials (short; only (1) Packages and R Code; (2) Documentation and maybe (3) Unit testing).
  • R packages (this is the best resource and you should read it whenever you can).

Also I recently discovered the rOpenSci's packaging guide (medium).

@maurolepore
Copy link
Contributor

@ervanSTRI,

RE

... data.table doesn't know how to deal with " ".

Can you create a minimal example that reproduces the problem? The only issue related to data.table that might have some connection is this r-lib/styler#445 (and it has been fixed).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants