Coder Social home page Coder Social logo

descriptiver's Introduction

descriptiveR

The goal of descriptiveR is to make cleaning column names easier, it also helps you to create descriptive stats in a very friendly way..

Installation

You can install the development version of descriptiveR from GitHub with:

# install.packages("devtools")
devtools::install_github("franc703/descriptiveR")
#> Downloading GitHub repo franc703/descriptiveR@HEAD
#>       v  checking for file 'C:\Users\rodri\AppData\Local\Temp\RtmpuIbB60\remotes269c3f805bd1\franc703-descriptiveR-dccbe10/DESCRIPTION'
#>       -  preparing 'descriptiveR':
#>    checking DESCRIPTION meta-information ...     checking DESCRIPTION meta-information ...   v  checking DESCRIPTION meta-information
#>       -  checking for LF line-endings in source and make files and shell scripts
#>   -  checking for empty or unneeded directories
#>       -  building 'descriptiveR_0.0.0.9000.tar.gz'
#>      
#> 
#> Installing package into 'C:/Users/rodri/AppData/Local/Temp/RtmpCCee1N/temp_libpath6284537b4846'
#> (as 'lib' is unspecified)

Example

This is a basic example which shows you how to solve a common problem:

library(descriptiveR)

When you have a data frame where the column names contain a prefix that you want to eliminate like in the mock dataframe I created below.

## basic example code
df <- data.frame(
pre_col1 = c(1,2,3),
pre_col2 = c(4,5,6)
)

Use col_replace() when you want to modify a common pattern across variable names.

col_replace(df, "^pre_", "")
#>   col1 col2
#> 1    1    4
#> 2    2    5
#> 3    3    6

In this example we have remove the prefix pre_ from the names of the columns.

descriptiver's People

Contributors

franc703 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.