• 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
  • Conferences
  • Python Books
  • About
    • Privacy Policy
You are here: Home / Archives for R / tidyverse

tidyverse

PCA on S&P 500 Stock Return Data

January 8, 2023 by cmdlinetips

PCA Plot S&P 500 Data : Highlight Select Sectors

This post is a fun exercise applying PCA (most in tidyverse framework) to stock data from S&P 500 index companies. With PCA on stock data from S&P 500, we can possibly do many interesting things, but we will focus on really simple things and try to see if PCA captures the general company trends from […]

Filed Under: PCA in tidyverse, R, R Tips, tidyverse Tagged With: PCA S&P 500 Stock Data

How To Reshape Tidy Data to Wide Data with pivot_wider() from tidyr

November 18, 2020 by cmdlinetips

Reshaping the data from one for form to another is one of the most common data munging activities. tidyr, R package part of tidyverse, provides core functions to manipulate datasets in wide or long form. In this post, we will see examples of one of tidyr’s core function pivot_wider() to convert data in long tidy […]

Filed Under: R, tidyr pivot_wider(), tidyverse 101 Tagged With: pivot_wider in R

R For Data Science Book Gets tidyr 1.0.0 Friendly

February 13, 2020 by cmdlinetips

pivot_longer(): wide form to long form

R for Data Science book by Garrett Grolemund and Hadley Wickham is the best book for doing data science with tidyverse. tidyverse, the meta-package, has loads of useful packages like tidyr, dplyr, and ggplot2 to make your life as data scientist easy. Last fall, tidyr package got a big update with version 1.0.0. Until now, […]

Filed Under: pivot_longer() tidyr, R, tidyr 1.0.0 Tagged With: R

10 Tricks for tidyverse in R

December 5, 2019 by cmdlinetips

tidyverse tips: bar plots with fct_lump()

Just happened to come across this tweet about David Robinson’s talk on “Ten Tremendous Tricks for Tidyverse”. It looked like a fantastic and useful talk. These ten tricks involve tidyverse functions one may not have heard of or thought of using in a scenario. The first four tidyverse tips is about counting and summarizing, next […]

Filed Under: 10 tidyverse tips, count() dplyr, dplyr add_count()

tidyr 1.0.0 is here. pivot_longer & pivot_wider replace spread & gather

September 16, 2019 by cmdlinetips

tidyr 1.0.0 is here.

tidyr version 1.0.0 is here with a lot of new changes. tidyr has been around for about five years and it has finally tidyr has reached version 1.0.0. There are four big changes in the new version of tidyr. One of the biggest changes is the new functions pivot_longer() and pivot_wider() for reshaping tabular dataserts. […]

Filed Under: pivot_longer() tidyr, pivot_wider() tidyr, tidyr 1.0.0 Tagged With: pivot_longer() tidyr, tidyr 1.0.0

  • 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 © 2025 · Lifestyle Pro on Genesis Framework · WordPress · Log in

Go to mobile version