R Programming Questions and Answers – Packages – 5

«
»

This set of R Programming Language Multiple Choice Questions & Answers (MCQs) focuses on “Packages – 5”.

1. _______ is not useful when developing a package since you have to install the package first.
a) Function
b) Library
c) Interface
d) Class
View Answer

Answer: b
Explanation: library() is not useful when developing a package since you have to install the package first. A library is a simple directory containing installed packages.
advertisement

2. Which function is used for seeing currently active libraries?
a) Curlib()
b) Currlib()
c) .libpaths()
d) Pathlibr()
View Answer

Answer: c
Explanation: A library is simply a directory containing installed packages. Everyone can use the dot libPaths() for seeing which libraries are currently active.

3. Which function is used for loading packages?
a) Library
b) Interface
c) Loader
d) Linker
View Answer

Answer: a
Explanation: library() function is used to load a package. library() is not useful when we are developing a package since you have to install the package first. A library is a simple directory containing installed packages.

4. The job of the __________ file is to store important metadata about your package.
a) Description
b) Interface
c) Thinker
d) Loader
View Answer

Answer: a
Explanation: The job of the DESCRIPTION file is to store the metadata about your package. When you first start writing packages, you’ll mostly use these metadata to record what packages are needed to run your package.

5. DCF is an abbreviation for__________
a) Debian control function
b) Differentiative common function
c) Debian control format
d) Debian common format
View Answer

Answer: c
Explanation: DESCRIPTION uses a very simple file format called DCF, the Debian control format. When you first start writing packages, you’ll mostly use these metadata to record what packages are needed to run your package.
advertisement

6. Which of the following is most important when releasing the package?
a) Versioning
b) Developing
c) Redundancy
d) Functioning
View Answer

Answer: a
Explanation: Versioning is most important when you release your package. Usually, people don’t have exactly the same versions of packages installed that you do.

7. Which of the following is called a one-line description of the package?
a) Function
b) Title
c) Interface
d) Class
View Answer

Answer: b
Explanation: Title is a one-line description of the package, and is often also shown in package listing. It should be plain text, capitalised like a title, and NOT end in a period.

8. To release a package to _____ you must pick a standard license.
a) R
b) CRAN
c) CRON
d) Studio
View Answer

Answer: b
Explanation: To release your package to CRAN, you must pick a standard license. Otherwise, it’s difficult for CRAN to determine whether or not it’s legal to distribute your package.

9. _____ package version is the sequence of atleast two integers separated by either. or -.
a) Java
b) C
c) R
d) Python
View Answer

Answer: c
Explanation: R package version is the sequence of atleast two integers separated by either. or -. When you first start writing packages, you’ll mostly use these metadata to record what packages are needed to run your package.
advertisement

10. The ________ number of your package increases with subsequent releases of a package.
a) Function
b) Studio
c) Version
d) Sequence
View Answer

Answer: c
Explanation: The version number of your package increases with subsequent releases of a package, but it’s more than just an incrementing the counter of the way the number changes with each release can convey information.

11. Which of the following is one of the most important aspects of a good package?
a) Title
b) Description
c) Documentation
d) Libraries
View Answer

Answer: c
Explanation: Documentation is one of the most important aspects of a good package. Without it, users won’t know how to use your package. Documentation is very much useful for the future.

12. ___________ are the most commonly documented object.
a) Interface
b) Class
c) Functions
d) Libraries
View Answer

Answer: c
Explanation: Function is very most commonly documented object. The introduction block, most functions have three tags namely @param, @examples and @return.

Sanfoundry Global Education & Learning Series – R Programming Language.

advertisement

Here’s the list of Best Reference Books in R Programming Language .

To practice all areas of R Programming Language, Here is complete set of 1000+ Multiple Choice Questions and Answers.

advertisement
advertisement
advertisement
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He is Linux Kernel Developer & SAN Architect and is passionate about competency developments in these areas. He lives in Bangalore and delivers focused training sessions to IT professionals in Linux Kernel, Linux Debugging, Linux Device Drivers, Linux Networking, Linux Storage, Advanced C Programming, SAN Storage Technologies, SCSI Internals & Storage Protocols such as iSCSI & Fiber Channel. Stay connected with him @ LinkedIn