• Skip to secondary menu
  • Skip to main content
  • Skip to primary sidebar

Python and R Tips

Learn Data Science with Python and R

  • Home
  • Python
  • Pandas
    • Pandas 101
  • tidyverse
    • tidyverse 101
  • R
  • Linux
  • About
    • Privacy Policy
You are here: Home / Archives for R / tidyverse

tidyverse

9 Ways To Create New Variables with tidyverse

February 17, 2019 by cmdlinetips

Add New Variables With tidyverse

When one wants to create a new variable in R using tidyverse, dplyr’s mutate verb is probably the easiest one that comes to mind that lets you create a new column or new variable easily on the fly. It is probably the go to command for every time one needed to make new variable for […]

Filed Under: Create New Column with Tidyverse, R Tips, tidyverse 101 Tagged With: add_column, Create New Column with Tidyverse, mutate_all, mutate_at, rename tidyverse, tidyverse, transmute

How To Collapse Multiple Text Columns in Dataframe Using Tidyverse?

November 16, 2018 by cmdlinetips

Often you may have a data frame, where multiple columns are related and you may want to combine those related columns into a single column. In an earlier post, we saw how we can collapse a numerical data frame with related columns using Python. In this post, we consider the problem of collapsing or combining […]

Filed Under: Collapse columns in tidyverse, R Tips Tagged With: collapse columns in tidyverse, combine text columns

How to Split Text in a Column in Data Frame in R?

March 22, 2018 by cmdlinetips

tidyr's separate() to split a column into multiple columns

Very often you may have to manipulate a column of text in a data frame with R. You may want to separate a column in to multiple columns in a data frame or you may want to split a column of text and keep only a part of it. tidyr’s separate function is the best […]

Filed Under: split a column in R dataframe, tidyr's separate(), tidyr's unite() Tagged With: split a column in R dataframe, tidyr's separate, tidyr's unite()

5 Big Ideas Behind Tidy Evaluation

February 27, 2018 by cmdlinetips

Ever wondered, how easy it is to write dataframe manipulation code without repeating yourself while using dplyr ? For example, if you are filtering a dataframe, you simply write instead of writing like this where you need to refer the dataframe multiple times and use “$” to access variables in the dataframe. The reason why […]

Filed Under: R Tips, tidy evaluation, tidyverse Tagged With: R Tips, tidy evaluation, tidy-eval

7 ways to read files with readr package in R

February 17, 2018 by cmdlinetips

read zipped file with readr

There are multiple ways read text files in rectangular, like csv file, tsv file or text file with common delimitters. readr package, part of tidyverse, offers seven functions to load flat text files easily. How to load a text file with readr package? read_csv(): to read comma delimited files read_csv2(): to read semicolon separated files […]

Filed Under: R Tips, Read CSV File in R, readr package, tidyverse Tagged With: How to Read CSV file in R, Read CSV File in R, read files with readr package

  • « Go to Previous Page
  • Page 1
  • Page 2
  • Page 3
  • Page 4
  • Go to Next Page »

Primary Sidebar

Subscribe to Python and R Tips and Learn Data Science

Learn Pandas in Python and Tidyverse in R

Tags

Altair Basic NumPy Book Review Data Science Data Science Books Data Science Resources Data Science Roundup Data Visualization Dimensionality Reduction Dropbox Dropbox Free Space Dropbox Tips Emacs Emacs Tips ggplot2 Linux Commands Linux Tips Mac Os X Tips Maximum Likelihood Estimation in R MLE in R NumPy Pandas Pandas 101 Pandas Dataframe Pandas Data Frame pandas groupby() Pandas select columns Pandas select_dtypes Python Python 3 Python Boxplot Python Tips R rstats R Tips Seaborn Seaborn Boxplot Seaborn Catplot Shell Scripting Sparse Matrix in Python tidy evaluation tidyverse tidyverse 101 Vim Vim Tips

RSS RSS

  • How to convert row names to a column in Pandas
  • How to resize an image with PyTorch
  • Fashion-MNIST data from PyTorch
  • Pandas case_when() with multiple examples
  • An Introduction to Statistical Learning: with Applications in Python Is Here
  • 10 Tips to customize ggplot2 title text
  • 8 Plot types with Matplotlib in Python
  • PCA on S&P 500 Stock Return Data
  • Linear Regression with Matrix Decomposition Methods
  • Numpy’s random choice() function

Copyright © 2026 · Lifestyle Pro on Genesis Framework · WordPress · Log in

Go to mobile version