
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Nizamuddin Siddiqui has Published 2307 Articles

Nizamuddin Siddiqui
3K+ Views
To create scatterplot using data frame columns, we need to convert the data frame columns into a variable and the value for each column will be read in a new column against each column name. This can be done with the help of melt function in reshape2 package.After that we ... Read More

Nizamuddin Siddiqui
901 Views
When we large number of values in each element of a list in R, we might want to have a look at some top values to understand the data characteristics. For this purpose, we can extract first n values from each element in an R list by using lapply function ... Read More

Nizamuddin Siddiqui
199 Views
To multiply each element of a larger vector with a smaller vector, we can perform outer product calculation with the help of %o% operator.For example, if we have two vectors say x and y where x is of shorter length than y then we can multiply each element of y ... Read More

Nizamuddin Siddiqui
365 Views
If we have categorical data in a data.table object and some values are duplicate then we might want to extract unique rows from that object.To extract unique rows by categorical column of a data.table object, we can use unique function and define the columns with by argument as shown in ... Read More

Nizamuddin Siddiqui
2K+ Views
The diagonal elements of a matrix occur at the position where column and row indices are same hence, we can make use of those indices to extract diagonal elements of a matrix if we do not want to use diag function.For example, if we have a matrix called M then ... Read More

Nizamuddin Siddiqui
229 Views
To create a data frame column with equally spaced values between 0 and 1, we can use ppoints function. For example, if we want to create a data frame df with hundred equally spaced values between 0 and 1 then we can use the below mentioned command −df

Nizamuddin Siddiqui
1K+ Views
To save the str output as a string in R, we can use capture.output function along with str function.For example, if we have a data frame called df and we want to store the str output of df as a string then we can use the command given below −capture.output(str(df))It ... Read More

Nizamuddin Siddiqui
1K+ Views
To find the moving standard deviation in an R data frame, we can make use of rollapply function of zoo package.For example, if we have a data frame called df and we want to find the 2 moving standard deviations then we can use the below given command −rollapply(df, width=2, ... Read More

Nizamuddin Siddiqui
111 Views
To separate first text value and the remaining text in an R, we can follow the below steps −First of all, create a vector.Then, use str_split function from stringr package to separate first text value and the remaining text.ExampleCreate the vectorLet’s create a vector as shown below −xRead More

Nizamuddin Siddiqui
182 Views
To create sequential index value for binary column assigning 0 to FALSE values in R data frame, we can follow the below steps −First of all, create a data frame with binary column.Then, use rle function along with sequence and lengths function to create sequential index column.ExampleCreate the data frameLet’s ... Read More