pmin and pmax
[This article was first published on R Tips's blog, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
Did you know that there are multiple versions of the min and max function. make sure that you are using the right one. pmin and pmax are the ‘parallel’ versions of the min and max function, meaning that they can take vector arguments and return vectors back. Much better than setting up your own apply function. So make sure that you are using the right version.
To leave a comment for the author, please follow the link and comment on their blog: R Tips's blog.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.