Jawaharlal Nehru Technological University Hyderabad

Jawaharlal Nehru Technological University Hyderabad B.Tech IV R PROGRAMMING Previous Question Paper (September - 2022 - R16)

B.Tech | IV | II | R16 | September - 2022

Answer PaperPaper Code: 138GTMaximum Marks: 75Time: 3 Hours

Answer any five questions. All questions carry equal marks.

Main

115 marks
a

Explain the basic features of R.

7 marks

Answer

R is a powerful, open-source programming language and software environment primarily used for statistical computing, data analysis, and graphical representation. Its core features include:

  • Open Source: R is free to use and distributed under the GNU General Public License, allowing users to modify and redistribute the source code.
  • Statistical Capabilities: It provides a wide variety of statistical techniques, including linear and non-linear modeling, classical statistical tests, time-series analysis, and clustering.
  • Data Visualization: R has excellent graphical capabilities, allowing for the creation of publication-quality plots, charts, and complex data visualizations through packages like ggplot2.
  • Extensibility: The functionality of R can be extended through user-created packages, which are hosted on repositories like CRAN, Bioconductor, and GitHub.
  • Object-Oriented Programming: R supports multiple object-oriented programming paradigms, allowing for complex data structures and modular code development.
  • Cross-Platform Compatibility: R runs on various operating systems, including Windows, macOS, and Linux.
  • Data Handling: It includes effective data storage and handling facilities, with a suite of operators for calculations on arrays and matrices.
b

What points to be considered in installing and run R?

8 marks

Answer

When installing and setting up R, the following considerations are essential for a stable and efficient environment:

  • System Requirements: Ensure the operating system (Windows, macOS, or Linux) is compatible with the latest version of R. Check for sufficient RAM and disk space, especially if working with large datasets.
  • CRAN Repository: Always download the R binary from the official Comprehensive R Archive Network (CRAN) to ensure the version is authentic, secure, and up-to-date.
  • RStudio Integration: While R can be run via the command line, it is highly recommended to install RStudio, an Integrated Development Environment (IDE) that provides a user-friendly interface, script editor, and workspace management.
  • Environment Variables: On some systems, ensure that the R installation path is correctly added to the system's PATH variable to allow execution from the terminal.
  • Package Management: After installation, understand how to manage libraries using the
    install.packages()
    and
    library()
    functions. Be aware of the default library path where packages are stored.
  • Permissions: Ensure you have administrative or appropriate user permissions to install software and write to the library directories, particularly when updating packages.
  • Version Control: If working on multiple projects, consider using tools like 'renv' to manage project-specific package versions to avoid dependency conflicts.
215 marks
a

What support is provided by R in handling complex numbers? Discuss suitable examples.

8 marks

Answer

Sign in to view the complete answer paper.

b

Write a R program to check whether a given number is a prime number.

7 marks

Answer

Sign in to view the complete answer paper.

315 marks
a

Compare and contrast matrices and data frames of R.

8 marks

Answer

Sign in to view the complete answer paper.

b

Describe scoping rules for functions in R.

7 marks

Answer

Sign in to view the complete answer paper.

415 marks
a

Illustrate the use of the following R operators in vector creation: Colon operator, sequence operator, repetition operator

8 marks

Answer

Sign in to view the complete answer paper.

b

Write R program to find runs of consecutive ones in a vector.

7 marks

Answer

Sign in to view the complete answer paper.

515 marks
a

What is a R List? How to access and work with lists? Explain with examples.

7 marks

Answer

Sign in to view the complete answer paper.

b

Demonstrate apply, lapply and sapply functions to list.

8 marks

Answer

Sign in to view the complete answer paper.

615 marks
a

Which matrix operations can be applied to Data frames? Explain with examples.

8 marks

Answer

Sign in to view the complete answer paper.

b

How to merge two data frames? Give illustrations.

7 marks

Answer

Sign in to view the complete answer paper.

715 marks
a

Illustrate the application of split and by functions to factors.

7 marks

Answer

Sign in to view the complete answer paper.

b

Consider student semester exam data in a table to compute average marks for a student and find average performance of the class in each subject.

8 marks

Answer

Sign in to view the complete answer paper.

815 marks
a

What is encapsulation? How does R support encapsulation?

7 marks

Answer

Sign in to view the complete answer paper.

b

With suitable data and R program explain conversion of a compressed matrix to an ordinary one.

8 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the solved question paper with answers of R PROGRAMMING from Jawaharlal Nehru Technological University Hyderabad for B.Tech ECE IV II, September - 2022, R16.

For the question paper without answers, switch to the Question Paper tab.

Other papers in R PROGRAMMING

Loading Question Papers

Fetching data from database...