EoN.EBCM_pref_mix_from_graph¶
- EoN.EBCM_pref_mix_from_graph(G, tau, gamma, rho=None, tmin=0, tmax=100, tcount=1001, return_full_data=False)[source]¶
Takes a given graph, finds degree correlations, and calls EBCM_pref_mix
I anticipate eventually adding an option so that the initial condition is not uniformly distributed. So could give rho_k
- Arguments:
- G networkx Graph
The contact network
- tau positive float
transmission rate
- gamma positive float
recovery rate
- rho positive float (default
None) initial proportion infected. Defaults to 1/N.
- tmin number (default 0)
minimum time
- tmax number (default 100)
maximum time
- tcount integer (default 1001)
number of time points for data (including end points)
- return_full_data boolean (default False)
whether to return theta or not
- Returns:
- if return_full_data == False:
returns t, S, I, R, all numpy arrays
- if …== True
returns t, S, I, R and theta, where theta[k] is a numpy array giving theta for degree k