![Trending Articles on Technical and Non Technical topics](/images/trending_categories.jpeg)
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- 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](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
71 Views
To extract number from string if string is in different format than normal in R data frame, we can follow the below steps −First of all, create a data frame.Then, use gsub function along with as.numeric function to extract the number.ExampleCreate the data frameLet’s create a data frame as shown ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
305 Views
To remove repeated numbers in sequence in R data frame column, we can follow the below steps −First of all, create a data frame.Then, use diff function and subsetting with single square brackets to remove repeated numbers in sequence.Example 1Create the data frameLet’s create a data frame as shown below ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
344 Views
To split a factor variable into n number of variables equal to factor size with full length in R data frame, we can follow the below steps −First of all, create a data frame.Then, use mtabulate function of qdapTools package to split the factor variable.ExampleCreate the data frameLet’s create a ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
3K+ Views
To find the column means by factor levels, we can use summarise function along with mean function after creating the group of factor levels with group_by function.For example, if we have a data frame called df that contains a factor column say F and a numerical column say Num then ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
818 Views
To replace total string if partial string matches with another string in R data frame column, we can follow the below steps −First of all, create a data frame with string column.Then, use gsub function to replace total string if partial string matches with another string.ExampleCreate the data frameLet’s create ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
466 Views
To find the number of common words between two string vectors, we would first need to split both the vectors using unlist and strsplit function and then we can apply length function along with intersect function.Check out the below examples to understand how it can be done.Example 1Following snippet creates ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
2K+ Views
To change the abline color created using ggplot2 in R, we can follow the below steps −First of all, create a data frame.Then, use ggplot2 to create the regression line with given slope and intercept.After that, create the same plot with colour argument to change the abline colour.ExampleCreate the data ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
1K+ Views
Most of the times in data analysis, the first name and last name of people are joined together or we can say they are stored in a single space hence we need to separate them to make the data easily readable. To create separate columns for first and last name ... Read More
![Nizamuddin Siddiqui](https://www.tutorialspoint.com/assets/profiles/218290/profile/60_42434-1594357075.jpg)
Nizamuddin Siddiqui
6K+ Views
To change the row order in an R data frame, we can use single square brackets and provide the row order at first place.For example, if we have a data frame called df that contains 10 rows then we can change the row order by using the command given below ... Read More