Directed Network Analysis

Hi,

I wish to analyse my dataset using a network analysis but my data doesn't fit the standard format that I have seen in examples especially the igraph package e.g. https://kateto.net/netscix2016.html

My data consists of prescription drug claims and the format is Prescriber -> Patient -> Pharmacy

Below is a sample of the data I have:

sample <- data.frame(prescriber = c("DocA","DocA","DocA","DocB","DocC"), patient = c(123,123,345,567,890), pharmacy = c("ABC","ABC","XYZ","XYZ","XYZ"))

I've tried googling how to analyse this type of data but I don't know even how to describe it, I've tried multi tier directed network, multigraphs, muti level graphs but I can't find any examples.

I tried looking for similar uses cases such as flight data where I have an origin, a stopover and a final destination but I've had no joy.

Is it possible to analyse such data with mutiple levels i.e. prescriber to patient to pharmacy using R?

Thanks in advance

Hi,

Have you looked into dagitty and ggdag for directed graphs and analysis?
Vignette ggdag

JW

1 Like

Not yet but I will do, thanks for pointing these packages out.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.