Skip to contents

Plot network diagram of Granger Causalities

Usage

# S3 method for GrangerInteraction
plot(x, mfrow = NULL, mar = c(1, 1, 1, 1), oma = c(1, 1, 1, 1), ...)

Arguments

x

GrangerInteration object

mfrow

passed to par()

mar

passed to par()

oma

passed to par()

...

passed through to plot.igraph()

Value

data.frame of P-Values

Examples

r <- get_recording("NIR_ABh_Puriya", fps = 25)
fv_list <- get_filtered_views(r, "Nose", n = 41, p = 3)
jv <- get_joined_view(fv_list)
jv <- subset(jv, Time <= 5*60)
l <- list(a = c(0, 100), b = c(100, 200), c = c(200, 300))
splicing_df <- splice_time(l)
sv <- get_spliced_view(jv, splicing_df)
gi <- get_granger_interactions(sv, c("Nose_x_Central_Sitar", "Nose_x_Central_Tabla"), lag = 1/25)
#> Calculating Granger Test: Nose_x_Central_Sitar <--> Nose_x_Central_Tabla
print(gi)
#> $gc_list
#> $gc_list$`Nose_x_Central_Sitar <--> Nose_x_Central_Tabla`
#> $df
#>   Res.Df Df          F   P_Value Segment                 Var1
#> 1   1498 -1 1.41163247 0.2349740       a Nose_x_Central_Sitar
#> 2   1498 -1 0.01985323 0.8879667       a Nose_x_Central_Tabla
#>                   Var2 Var3
#> 1 Nose_x_Central_Tabla     
#> 2 Nose_x_Central_Sitar     
#> 
#> $var1
#> [1] "Nose_x_Central_Sitar"
#> 
#> $var2
#> [1] "Nose_x_Central_Tabla"
#> 
#> $var3
#> [1] ""
#> 
#> $recording
#> $data_home
#> [1] "/private/var/folders/b0/vtr2rd_96119zlr64t5hvlgr0000gp/T/Rtmp9AFYAo/temp_libpath9e3f6307ab8/movementsync"
#> 
#> $data_path
#> [1] "/private/var/folders/b0/vtr2rd_96119zlr64t5hvlgr0000gp/T/Rtmp9AFYAo/temp_libpath9e3f6307ab8/movementsync/data"
#> 
#> $data_files
#>  [1] "NIR_ABh_Puriya_Annotation.rda"                     
#>  [2] "NIR_ABh_Puriya_Annotation_Influence.rda"           
#>  [3] "NIR_ABh_Puriya_Central_Feature_Sitar.rda"          
#>  [4] "NIR_ABh_Puriya_Central_Pose_Sitar.rda"             
#>  [5] "NIR_ABh_Puriya_Central_Pose_Tabla.rda"             
#>  [6] "NIR_ABh_Puriya_Metre_DrutTeental.rda"              
#>  [7] "NIR_ABh_Puriya_Metre_VilambitTeental.rda"          
#>  [8] "NIR_ABh_Puriya_Onsets_Selected_DrutTeental.rda"    
#>  [9] "NIR_ABh_Puriya_Onsets_Selected_VilambitTeental.rda"
#> [10] "NIR_ABh_Puriya_OptFlow_Central_Sitar.rda"          
#> 
#> $stem
#> [1] "NIR_ABh_Puriya"
#> 
#> $fps
#> [1] 25
#> 
#> attr(,"class")
#> [1] "Recording"
#> 
#> $order
#> [1] 1
#> 
#> attr(,"class")
#> [1] "GrangerTime"
#> 
#> 
#> $sig_level
#> [1] 0.05
#> 
#> $lag
#> [1] 0.04
#> 
#> $cond_column
#> [1] ""
#> 
#> attr(,"class")
#> [1] "GrangerInteraction"