ComeçarComece de graça

Create time series objects

A time series object contains the aggregated frequency of tweets over a specified time interval.

Creating time series objects is the first step before visualizing tweet frequencies for comparison.

In this exercise, you will be creating time series objects for the competing sportswear brands Puma and Nike.

Tweets extracted using search_tweets() for "#puma" and "#nike" have been pre-loaded for you as puma_st and nike_st.

Este exercício faz parte do curso

Analyzing Social Media Data in R

Ver curso

Exercício interativo prático

Experimente este exercício completando este código de exemplo.

# Create a time series object for Puma at hourly intervals
puma_ts <- ___(puma_st, by ='___')

# Rename the two columns in the time series object
names(puma_ts) <- c("time", "puma_n")

# View the output
head(puma_ts)
Editar e executar o código