-
Notifications
You must be signed in to change notification settings - Fork 533
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH: Interface for R #3291
ENH: Interface for R #3291
Conversation
mostly a copy-paste of the matlab interface
Codecov Report
@@ Coverage Diff @@
## master #3291 +/- ##
==========================================
+ Coverage 65.05% 65.07% +0.02%
==========================================
Files 306 307 +1
Lines 40279 40327 +48
Branches 5320 5326 +6
==========================================
+ Hits 26202 26242 +40
- Misses 13006 13012 +6
- Partials 1071 1073 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good. I started reviewing this a while back, but I guess got lost in my sea of tabs. Here are some suggestions, and could you make a test (in nipype/interfaces/tests/test_r.py
) that skips if R is not found? e.g.:
@pytest.mark.skipif(no_r, "No R command found")
def test_basic_Rscript():
...
@Terf I'm going to try to make a release in the next couple days. If you want to try to finish this off, I'd love to include it! |
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
@effigies awesome! I just committed some tests, let me know if there any problems |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're getting some test failures that should be fixed in master
, if you want to merge.
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Can you merge latest |
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm good with this, at this point. I notice that the outputs are pretty verbose, so I suspect that at some point we'll want to add inputs to allow for control of that. If you want to adjust the behavior at all before merge, I'm happy to wait. Otherwise we can merge now and improve later.
Awesome, thanks. If you're not already in the Zenodo file and would like to be included as an author on releases, please post on #3336 with your name, affiliation and ORCID. |
Since this PR’s already merged I’ll submit a new PR with inputs to control the verbosity of outputs. Right now, calling I wonder if these changes should just apply to the R interface, or we should abstract the R and matlab interfaces into an “AbstractLanguage” class that could be extended by other language interfaces to reduce code reuse. After all, the R interface copied much of the code from the matlab interface, and I think it could be useful to have interfaces for Java and Julia which would worsen the code duplication problem between them. That'd be great if I could be included as an author on releases! Thanks, and I hope to make more significant contributions in the future. |
Summary
Like matlab, R has many useful neuroimaging tools but isn't as nice of a scripting language as python. This PR creates an R interface akin to the matlab interface, so R code may be more easily wrapped by nipype.
List of changes proposed in this PR (pull-request)
Acknowledgment