test_that("multiplication works", {
df<-data.frame(Time=c("2020-01-01 00:10:09", "2020-01-01 01:12:34" ,
"2020-01-01 06:38:09","2020-01-02 03:21:51", "2020-01-02 04:34:09",
"2020-01-02 07:09:38" , "2020-01-03 02:15:25","2020-01-03 05:35:45",
"2020-01-03 06:54:14"),
Cat=c('A','B','C','C','A','B','C','A','B'))
newdf<-data.frame(Time=c("2020-01-04 01:30:20", "2020-01-04 04:19:14" ,
"2020-01-04 06:51:29"),Cat=c('A','B','A'))
seqlist<-SeqList(df,'%Y-%m-%d')
sqslist<-SQSList(seqlist,2)
newseqlist<-SeqList(newdf,'%Y-%m-%d')
newsqslist<-SQSList(newseqlist,2)
allsqs<-AllSQS(c('A','B','C'),2)
sqsindex<-SQSIndex(allsqs,sqslist)
newsqsindex<-SQSIndex(allsqs,newsqslist)
df1<-TestSeqScore(newseqlist[[1]],seqlist,allsqs,newsqsindex,sqsindex,c('A','B','C'),
c(1/3,1/3,1/3),2,1,0.5)
load('TestSeqScore_testdata.Rdata')
expect_equal(df1,testseqscore_testdata)
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.