install package

install.packages("difR")
Installing package into ‘C:/Users/TOSHIBA/Documents/R/win-library/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://mirror.its.sfu.ca/mirror/CRAN/bin/windows/contrib/3.6/difR_5.0.zip'
Content type 'application/zip' length 979760 bytes (956 KB)
downloaded 956 KB

package ‘difR’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
C:\Users\TOSHIBA\AppData\Local\Temp\RtmpghBZJG\downloaded_packages

Hi, welcome!

Could you explain what your problem is? so far you are not showing any error message.

How can I solve this problem

You are not showing any problem so far so I don't know what to tell you about it.

To use a package, you first have to

  1. Install it on your computer (which you have successfully done)
  • which is like buying a book and putting it on your bookshelf
  1. And also access it in your session with

library(package_name)

in your case, this would be

library(difR)

  • this is like taking the book off the shelf and opening it

Now you can use the functions in the package.

You may be missing the library step.

Alternatively, you can work around the library step (if you have the package already installed)
by specifying the package each time you call a function, with the double colon structure.
One example with the readr package:

readr::read_csv("my_file")

this will read in a csv file

If you are using functions from a package more than once, it is easier to do the library step.

Welcome to the RStudio Community!

1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.