Skip to contents

Calculates the daily trading volume change status of a stock within a given period of time

Usage

volume_change(stock_ticker, start_date, end_date)

Arguments

stock_ticker

A string related to ticker of the stock or ETF, such as "AAPL"

start_date

A date in string format of "YYYY-MM-DD" related to start of data extraction

end_date

A date in string format of "YYYY-MM-DD" related to end of data extraction

Value

A data frame with dates and their corresponding trading volume and changes

Examples

        volume_change('AAPL', '2017-01-01', '2017-01-10')
#> # A tibble: 5 x 3
#>   date          volume Price_change
#>   <date>         <dbl> <chr>       
#> 1 2017-01-03 115127600 Increase    
#> 2 2017-01-04  84472400 Decrease    
#> 3 2017-01-05  88774400 Increase    
#> 4 2017-01-06 127007600 Increase    
#> 5 2017-01-09 134247600 Increase