Commit ce2ac31e authored by Mark Penney's avatar Mark Penney
Browse files

Deleted...

Deleted CovidAlertVaccinationModel/data/canada-network-data/POLYMOD/AALPoisPriors.csv, CovidAlertVaccinationModel/data/canada-network-data/POLYMOD/Duration-priors.py files
parent 6094d595
,Age_in,Age_out,location,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94
0,Y,Y,home,0.0052316921736722324,0.005056469104736709,0.004496192300909459,0.00493731576024464,0.005899528397661227,0.006236983910250035,0.005583317279107057,0.0047357692362101364,0.004121998500378075,0.003747185398793234,0.003533986837031761,0.0034227974810930534,0.0033811204998198435,0.003398722085431882,0.003483511993552351,0.0036601976016191486,0.003973115754861902,0.004496396872520209,0.005358128033634342,0.006793422210280659,0.009260688645796489,0.013690111748345333,0.021888747532995682,0.03604329518099982,0.0515613694867789,0.05155703230139411,0.03899736288935219,0.02796143785841038,0.02100685119715862,0.016806209345426714,0.014209951010479078,0.01255464551149877,0.01147240859696657,0.01075287939743347,0.010270123305829748,0.009945300013813973,0.009727168751570432,0.00958148919967121,0.009484973278801967,0.009421646597336696,0.009380540626747634,0.00935415898461001,0.009337422113862662,0.009326926140938325,0.00932041859465801,0.009316428597602469,0.009314008517406535,0.009312555924385974,0.009311692794970077,0.009311184885186775,0.009310888788431953,0.009310717720089954,0.00931061973931987,0.009310564086544794,0.00931053272912262,0.009310515197280616,0.009310505468282533,0.009310500108148115,0.009310497175512421,0.009310495581770752,0.00931049472126732,0.00931049425957248,0.009310494013357892,0.009310493882826868,0.009310493814019268,0.00931049377794807,0.009310493759139187,0.00931049374938212,0.009310493744345907,0.009310493741758913,0.009310493740436191,0.009310493739762895,0.009310493739421624,0.009310493739249347,0.009310493739162706,0.009310493739119288,0.009310493739097604,0.009310493739086807,0.00931049373908144,0.009310493739078786,0.00931049373907747,0.009310493739076818,0.009310493739076503,0.009310493739076343,0.009310493739076267,0.009310493739076229,0.00931049373907621,0.0093104937390762,0.009310493739076196,0.00931049373907619,0.00931049373907619,0.00931049373907619,0.00931049373907619,0.00931049373907619,0.00931049373907619
1,Y,Y,workschool,0.010595360727073995,0.009658524250005475,0.00837897845785893,0.009200545683009709,0.011184560339961657,0.012150127981191786,0.011082961530505489,0.009463402812176263,0.008246222753929073,0.007493692958046602,0.007063760422665971,0.006839372162152722,0.006755830618825968,0.006793079455062243,0.006968002517757658,0.007332173334759427,0.007978440334897871,0.009063408140009537,0.010860790187366196,0.013879373351084287,0.019122352550667247,0.028627651064167363,0.046168755766901756,0.07461327180944592,0.09805476859507771,0.08814843185447384,0.06373903153763212,0.04555268853053152,0.0345020606370817,0.027851912749176436,0.023725029911313873,0.02108060021076651,0.019344159682548323,0.018185567368271604,0.017405717579087952,0.016879101102319816,0.016523739675147368,0.016284723384475324,0.01612471500255362,0.016018161096247614,0.015947572211752598,0.015901028533697476,0.015870459855706363,0.01585044372385627,0.015837364302632113,0.015828827158989197,0.015823256087137375,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
2,Y,Y,rest,0.027985134355286646,0.02848122568549977,0.023905949509168706,0.029420119563651464,0.04535404068421663,0.05383931634307969,0.04021214259599724,0.02791739665233143,0.021456187434322302,0.01819793430451911,0.016524017331520296,0.01568024750285392,0.01532562983107545,0.015329982289837554,0.015691060854195398,0.016501874031356382,0.01794515975821284,0.020307124404439655,0.023989891866323446,0.029430237255968987,0.036628991832078295,0.04388723223088464,0.04708406247159959,0.04358243717541758,0.036176307018777346,0.02886651608046342,0.023236188496648425,0.01926464328860041,0.01653090438532795,0.014651323146006473,0.01335206900710246,0.012449369807616559,0.011820657886483584,0.011383088136821979,0.011079628645761563,0.010870375670911533,0.010727108150691821,0.010629782117978328,0.010564185198048396,0.010520302821199546,0.010491143302024476,0.010471877680616977,0.010459207622085116,0.010450904087877171,0.010445475075862307,0.010441930143855131,0.01043961626540209,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
3,Y,M,home,0.005112345641835258,0.004845468304028885,0.004288319043373468,0.004706007651296263,0.005645061955447637,0.006033021141088567,0.005463625962741383,0.004667310438341619,0.004076753073791632,0.0037123366845486527,0.00350406744024623,0.0033953346404811823,0.003354922599508746,0.0033732053681413145,0.0034584334917560954,0.0036355989226582257,0.0039494777501852445,0.00447518789097349,0.0053433359809595396,0.006795907686280633,0.009311442419293575,0.013883619231527004,0.022524596188903744,0.03792875430341121,0.055247044888453486,0.05455554728443715,0.04015999405779617,0.028255100873335895,0.021005263887244163,0.016707179521635154,0.014078478816442232,0.012412916095026302,0.011328181461598828,0.010608779094696904,0.0101268915716499,0.0098030015322132,0.009585652838816051,0.009440565168684816,0.009344471770849665,0.00928143543324357,0.009240523477479813,0.009214268651682822,0.009197613165694124,0.009187168598948687,0.009180693067280974,0.009176722753423967,0.00917431463179335,0.009172869223849354,0.009172010366373252,0.009171504971315999,0.009171210340880498,0.00917104011979968,0.009170942624339207,0.009170887247229505,0.00917085604513383,0.009170838600135518,0.00917082891933021,0.009170823585747424,0.009170820667638685,0.0091708190817917,0.009170818225550824,0.009170817766143018,0.009170817521148065,0.009170817391263637,0.009170817322796879,0.009170817286904361,0.009170817268188648,0.009170817258479916,0.00917081725346865,0.009170817250894471,0.009170817249578299,0.00917081724890834,0.009170817248568759,0.009170817248397335,0.009170817248311125,0.009170817248267918,0.009170817248246343,0.0091708172482356,0.00917081724823026,0.009170817248227619,0.00917081724822631,0.009170817248225662,0.009170817248225344,0.009170817248225188,0.009170817248225112,0.009170817248225074,0.009170817248225056,0.009170817248225046,0.00917081724822504,0.009170817248225037,0.009170817248225037,0.009170817248225036,0.009170817248225036,0.009170817248225036,0.009170817248225036
4,Y,M,workschool,0.04011746322641201,0.035780344808579105,0.02736140198018712,0.031408379338760894,0.042620605769014025,0.04426344665539578,0.03312959241613504,0.024083689808960154,0.019132081402630903,0.016541718227361994,0.015180929641153064,0.014486841259046116,0.014194429826282376,0.014201008681493684,0.014506186987522162,0.015185763683558437,0.01638435086814531,0.01832063627872797,0.02129052996911703,0.02561156826984329,0.031346350097392055,0.03757659186625681,0.04173558468623106,0.0412198209932865,0.03659727919780871,0.030703520738495877,0.02551019089643341,0.021551789748067172,0.018699532082788378,0.016683290400641478,0.015265235141586883,0.014269013220844295,0.013570115582525277,0.0130813496014167,0.012741287850540852,0.012506284050817275,0.012345149177655168,0.01223557683859768,0.012161676918352134,0.012112218139380432,0.012079343451085483,0.01205761899299244,0.012043330044579118,0.012033964755823169,0.012027841210945588,0.012023842632435434,0.012021232584694204,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
5,Y,M,rest,0.08102548098493811,0.04717605936202488,0.030579243739009315,0.032108494029914385,0.03911710304044279,0.03849056142022347,0.02996231783465844,0.022857263698935395,0.01872047659597186,0.01646632113977095,0.015253990052390368,0.014626887163612889,0.01435882754128991,0.014358865419315034,0.014623654524298944,0.015212894485898798,0.01623619791842362,0.01784365181852543,0.020203437567755864,0.023423817064266966,0.027344194371782298,0.031191261126402525,0.03351770185640573,0.033152138993547645,0.030411474740185573,0.02667893345646593,0.023107874550701988,0.02018042172119016,0.017947847136858732,0.016302080270067448,0.015109003864197806,0.014252497590891517,0.013642306147902204,0.013210914437927648,0.01290847331925838,0.012698354194580298,0.012553752139983044,0.012455174718381458,0.012388576696650493,0.012343953640212176,0.012314270453077491,0.012294645043350039,0.012281732381159162,0.01227326727447342,0.012267731519381483,0.012264116417269487,0.01226175653602863,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
6,Y,O,home,0.016433595854285835,0.018111192728920776,0.015583694909630736,0.019018439683244508,0.027985742575987176,0.03088545636722477,0.022709382268131642,0.015992533402527476,0.0124479346454897,0.01064039620260657,0.009704772231591078,0.009231685744343276,0.009034076059709436,0.009041009965953787,0.009253536283792912,0.009727439116058187,0.010571687576761362,0.011960315892631366,0.014151775405758068,0.01747831439228496,0.02215647987843667,0.02758105050637902,0.03132827290766814,0.03062433657519727,0.026227615055229296,0.02112682747531171,0.01697796533767348,0.01400070402047876,0.011944466695529675,0.010532585940876624,0.009559068762467707,0.008884313858104903,0.008415302832061086,0.008089452879935339,0.007863904594576176,0.00770879420237883,0.0076030465019595464,0.0075316900802486555,0.007484084668587674,0.0074527043912158706,0.007432273015126311,0.007419134310685623,0.007410788384877169,0.007405550323503014,0.007402301078881364,0.007400308241167776,0.007399099283477298,0.007398373553869621,0.00739794229659333,0.007397688512358585,0.007397540559964227,0.007397455080070259,0.007397406120384673,0.007397378311308439,0.007397362642311187,0.007397353881808543,0.00739734902031242,0.007397346341898463,0.0073973448764847825,0.007397344080105212,0.007397343650118712,0.007397343419413582,0.007397343296382166,0.007397343231156882,0.007397343196774286,0.007397343178749801,0.007397343169351157,0.007397343164475631,0.007397343161959075,0.007397343160666377,0.007397343160005422,0.007397343159668983,0.007397343159498452,0.007397343159412368,0.007397343159369072,0.007397343159347376,0.00739734315933654,0.007397343159331147,0.007397343159328463,0.007397343159327138,0.00739734315932648,0.007397343159326156,0.007397343159325997,0.007397343159325917,0.00739734315932588,0.00739734315932586,0.00739734315932585,0.007397343159325847,0.007397343159325845,0.007397343159325842,0.007397343159325842,0.007397343159325842,0.007397343159325842,0.007397343159325842,0.007397343159325842
7,Y,O,workschool,0.053742528585024284,0.03851003245428218,0.02612124712812236,0.02676378990697757,0.030946219110340088,0.029817224146457443,0.023816397821647965,0.01872021819813404,0.01563691575024582,0.013912395425066367,0.012971592692740326,0.01248373173958169,0.012281591516932054,0.012301002252149574,0.012548684914812158,0.013086379683253596,0.014025878925707905,0.015533130032277605,0.017835258433680123,0.021204748105716965,0.0258431174950525,0.03151304453122583,0.03692313389829369,0.03978942399936284,0.038760662451405525,0.034935610129822714,0.030367567733607024,0.026317296460015797,0.023147365696240638,0.020798608998054177,0.01910029513039758,0.01788694500638452,0.017026735732537625,0.0164211100152786,0.015997901639907434,0.015704598533996056,0.015503107206442194,0.015365919230366355,0.015273316561900799,0.015211306144039228,0.015170073348494368,0.015142819022006952,0.015124890025429364,0.015113137742836144,0.015105452924728308,0.015100434635840187,0.015097158883183656,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
8,Y,O,rest,0.059296640851750765,0.045704638641251016,0.03214047216784804,0.03684100040848197,0.05200104808105835,0.05553921516621309,0.04071432727274579,0.028862825235322832,0.02257897546509212,0.01935654222650018,0.017680620435703103,0.01682558773199942,0.016453257295344224,0.01642624451693382,0.016726587699114545,0.01741669284129351,0.018616925163358278,0.020483202935327138,0.02315365705329955,0.02659838185651704,0.03030509785267658,0.03299849664425017,0.033176745078294545,0.03058310306418141,0.02651984311029222,0.02244243248940145,0.019060101885862577,0.016488135533000412,0.014605526049152759,0.013249226946046423,0.012278842116544834,0.01158756749890502,0.01109737660440797,0.010751815183971829,0.01050998495630526,0.010342168741185135,0.010226765513070984,0.010148131808380744,0.010095024615869027,0.010059448398047526,0.010035786432144037,0.010020143450268769,0.01000985166450782,0.010003104978856245,0.009998693097038474,0.009995811983505395,0.009993931258677471,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
9,M,M,home,0.00982418328209178,0.009497634250183726,0.008083149109805177,0.008978054756925086,0.011089029388284592,0.011616085039530965,0.00983706329830756,0.007921924034156985,0.006672165457451111,0.005952797877249853,0.005556127199424317,0.005351052005468052,0.0052703255865746155,0.005290441766049147,0.0054202038847508014,0.005696456351518112,0.00618712635065272,0.007004984322651887,0.008339057983800599,0.01051428792988074,0.014081906639171856,0.01984511860033005,0.02824068360064395,0.03678260525305615,0.03897827925991457,0.03358682466075196,0.026368078622014658,0.02068214570372351,0.01680842366413935,0.014248083495421775,0.01254839006860869,0.011406698486496003,0.01063206837571416,0.010103446039306907,0.009742259052490291,0.0094961483421739,0.009329437350443857,0.009217441177539785,0.009142946815832543,0.009093940314231786,0.009062074751981567,0.009041600673595778,0.009028602336773902,0.009020447169585067,0.009015389501768447,0.009012287932372551,0.009010406515478568,0.009009277168889192,0.009008606086317756,0.009008211177766158,0.009007980954387056,0.009007847943006173,0.009007771759325517,0.009007728487119232,0.009007704105463405,0.009007690473740637,0.009007682909044077,0.009007678741317839,0.009007676461071961,0.00900767522187162,0.009007674552794437,0.0090076741938075,0.009007674002365415,0.009007673900872119,0.009007673847371344,0.00900767381932449,0.0090076738046998,0.009007673797113277,0.009007673793197413,0.009007673791185916,0.009007673790157442,0.009007673789633928,0.009007673789368573,0.009007673789234621,0.009007673789167255,0.009007673789133494,0.009007673789116637,0.009007673789108243,0.009007673789104066,0.009007673789102002,0.009007673789100982,0.009007673789100475,0.009007673789100229,0.009007673789100104,0.009007673789100045,0.009007673789100014,0.0090076737891,0.009007673789099991,0.00900767378909999,0.009007673789099984,0.009007673789099984,0.009007673789099982,0.009007673789099982,0.009007673789099982,0.009007673789099982
10,M,M,workschool,0.09423239817664215,0.05161500064336109,0.03151212394436014,0.03133955897694827,0.03520567492677907,0.03262369797420946,0.025390604437134177,0.01975150980243179,0.016440442148523027,0.014609939419612895,0.01361551946257202,0.01309872541945409,0.012879022665587443,0.012884128668595136,0.013113711107355885,0.013620031766034671,0.014497601137429863,0.015876920524712127,0.017911588810591222,0.02073017537522897,0.024296872740175633,0.028143910459157904,0.03117876856973841,0.032153235392938205,0.030761952931131247,0.02790050554343152,0.024715357736394692,0.021885511581599282,0.01962433871160123,0.017910029405912943,0.016645475558990985,0.01572759214613113,0.01506898983877754,0.01460118067906972,0.014272181412223438,0.01404313232276714,0.013885281200776804,0.013777570184148564,0.01370475566299183,0.01365594681013005,0.013623470178475787,0.013601993890897527,0.013587861718894204,0.01357859640622622,0.013572537041578491,0.013568579864065393,0.013565996624210515,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
11,M,M,rest,0.12108978543062811,0.05665911186605433,0.03401942793414659,0.035094067154252846,0.04236725201606365,0.04119329879043893,0.03176959278232039,0.0241327078870632,0.019730630993905058,0.017341495509560694,0.016057809775355404,0.01539119225141457,0.015098445673387193,0.015077468330201751,0.015314685038969522,0.01585578969822797,0.016785269544754813,0.0182038340499871,0.02018514313395736,0.022679551731466005,0.025346673463237615,0.02743169201098148,0.02802716536967588,0.026791639633537936,0.024283710503248727,0.021404317898496266,0.018775794021802423,0.016634674726142835,0.014989220874633247,0.013762524063585333,0.012863549522932588,0.012212265406181663,0.011744936800553675,0.011412749410258424,0.011178929027310634,0.011016017987158176,0.010903677373363287,0.010826985508940125,0.010775123313116777,0.01074035113711054,0.010717210627913311,0.010701906541176698,0.010691835184640704,0.010685231907299473,0.010680913337259179,0.010678092959979735,0.010676251797307938,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
12,M,O,home,0.019897744489110778,0.020981356898593727,0.01668307684447705,0.019084075084053062,0.025166194606124074,0.02510344205604621,0.018554189266293104,0.01353375947925505,0.010802473261961692,0.009370893360530593,0.008617312201299118,0.008232887815719441,0.008072146753918558,0.00807939069110018,0.008256206384893291,0.008647743997169883,0.009340143322533204,0.010467232113876079,0.012221825592892453,0.014847332341684654,0.018522670583173004,0.02294847633470563,0.02667064728464465,0.027516459920977853,0.02507941235027884,0.021200163711263313,0.017562152303157316,0.014739291871966667,0.012700747509346433,0.011263760719335934,0.010256975934415493,0.009552139516778685,0.009059055128361495,0.00871503193678555,0.008476236984477388,0.008311709432625528,0.0081994010371556,0.008123554232827094,0.008072924977873859,0.008039539258000565,0.008017796973297266,0.008003813115699457,0.00799492946073577,0.007989353564118628,0.007985894621375948,0.007983773120139322,0.007982486089746115,0.00798171348677295,0.007981254373063474,0.007980984195162999,0.00798082668521933,0.007980735683328648,0.007980683560817957,0.007980653955248322,0.007980637274015287,0.007980627947572752,0.007980622772017325,0.007980619920574058,0.007980618360492565,0.00798061751266573,0.007980617054901482,0.007980616809292468,0.007980616678313042,0.007980616608874109,0.007980616572270349,0.007980616553081459,0.007980616543075645,0.007980616537885156,0.007980616535206026,0.007980616533829817,0.007980616533126162,0.007980616532767989,0.007980616532586441,0.007980616532494796,0.007980616532448704,0.007980616532425606,0.007980616532414072,0.007980616532408329,0.007980616532405473,0.007980616532404061,0.007980616532403362,0.007980616532403013,0.007980616532402845,0.007980616532402762,0.007980616532402722,0.007980616532402701,0.00798061653240269,0.007980616532402686,0.007980616532402684,0.00798061653240268,0.00798061653240268,0.00798061653240268,0.00798061653240268,0.00798061653240268,0.00798061653240268
13,M,O,workschool,0.24866540327267558,0.06213129258305212,0.032473566409697334,0.030398919510781434,0.03215871092742879,0.028767829901916956,0.022438148110172786,0.01768002232262089,0.014870267675852731,0.013302244841102446,0.012443854103280385,0.01199347901955301,0.011795418490703853,0.011783429708275362,0.011949566161630879,0.012325239354524587,0.012967007836418123,0.013941403631514238,0.015299547410260529,0.017026346142297026,0.01895501650355144,0.0206904495872771,0.021685696881550528,0.021567889504797683,0.020437192635157496,0.018754514815086283,0.01698664091778884,0.01540940014992376,0.014120591319185713,0.013118648135284374,0.012362886021566655,0.011804306081555143,0.011397894341858622,0.01110620578175752,0.010899511611153778,0.010754832083167095,0.010654745816783048,0.010586271311014207,0.010539898010849216,0.010508775316680418,0.010488049872567058,0.010474337024063937,0.010465310239597451,0.010459390717804365,0.010455518848142914,0.01045298999829129,0.010451339059784895,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
14,M,O,rest,0.1334777481098032,0.06754740761648743,0.038358799671473744,0.03894835076165969,0.04582759528140988,0.042206371890422346,0.03125524149625601,0.02334947830451114,0.018977700931723455,0.01664352540799844,0.015397820818731933,0.014751739411508548,0.01446517412608448,0.01443625864258077,0.01464784751435308,0.015137980715713865,0.015978779937537956,0.017253044574260044,0.019012165389511244,0.021190170995190574,0.023467766426874894,0.025194325498449948,0.02563188979551661,0.024527007608696867,0.02234739806078967,0.01983637192861358,0.017521034137157405,0.01561480095644629,0.014136211797377618,0.013025724276256244,0.012207294435154292,0.011611856674426883,0.011183278492406802,0.010877955150659148,0.010662701555149588,0.010512558402072249,0.01040894143531501,0.01033816693522803,0.010290288777508318,0.010258179858502458,0.010236808186586418,0.010222672377374334,0.010213369169994314,0.01020726923851203,0.010203279734205999,0.010200674210451233,0.010198973283055983,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
15,O,O,home,0.00653121510676935,0.006080357668624411,0.005188338605003396,0.005544927850864068,0.006412614731911308,0.006536980663643201,0.005724093145841693,0.004819787952984139,0.004190327862237522,0.003810988755813858,0.0035961968395344713,0.0034841552794301392,0.003441565530366174,0.0034575921730097534,0.0035393130555084027,0.0037099461015401756,0.004010817050071068,0.004509468515876109,0.005318625108477837,0.006635217420188378,0.008816172497081677,0.012506689279164448,0.018729696473808517,0.028181148638627057,0.037801528162095796,0.039673533960473975,0.0335173725471372,0.026191912761515015,0.020720389792070144,0.017080251535961943,0.01470061708034618,0.013131160416744964,0.012083040715045899,0.011376594283307718,0.010898335680063808,0.010574611532590017,0.010356351104528323,0.010210198108015338,0.010113198048176782,0.010049479980989151,0.010008088715791985,0.009981511022179177,0.009964644526309038,0.009954065185400127,0.009947505146360952,0.009943482659802947,0.009941042760788277,0.009939578231133252,0.009938707994455233,0.009938195897332582,0.00993789735774971,0.009937724877495913,0.009937626087850418,0.00993756997557447,0.009937538359227808,0.00993752068261566,0.009937510873277917,0.009937505468880246,0.009937502512027074,0.009937500905124356,0.00993750003751491,0.009937499572007404,0.009937499323759577,0.009937499192150631,0.009937499122774817,0.009937499086405744,0.009937499067441536,0.009937499057603895,0.009937499052526095,0.009937499049917737,0.00993749904858409,0.009937499047905236,0.009937499047561147,0.009937499047387447,0.00993749904730009,0.00993749904725631,0.009937499047234451,0.009937499047223564,0.009937499047218154,0.009937499047215475,0.00993749904721415,0.009937499047213492,0.009937499047213173,0.009937499047213014,0.009937499047212937,0.009937499047212896,0.00993749904721288,0.009937499047212868,0.009937499047212866,0.009937499047212861,0.009937499047212861,0.009937499047212861,0.009937499047212861,0.009937499047212861,0.009937499047212861
16,O,O,workschool,0.079336199604971,0.042764044445948404,0.027743451069894814,0.02884039959494611,0.03624372963002831,0.04082623977580251,0.03668089557776497,0.030184878778297654,0.025527000616135633,0.022758987240798098,0.021209234554533017,0.02038827208029988,0.020023780367421806,0.019995633982350627,0.02028591693023873,0.02094312005288935,0.022049029710695257,0.02367344493814067,0.025792647711625587,0.02815052275074422,0.030120238359804243,0.030817597934976317,0.02968357171599754,0.027025181690733303,0.023734635324460653,0.020590346809497066,0.017961485335486808,0.015911907775194085,0.014370706819993037,0.013233829258002532,0.012404805002259716,0.011805509469257371,0.011375850573717072,0.011070512781391498,0.010855588152644357,0.01070582729950497,0.010602543022545735,0.0105320266625635,0.010484336908898911,0.010452360431649991,0.010431079582543122,0.010417005006415639,0.010407742599071764,0.010401669634131382,0.010397697858329011,0.010395103952045312,0.010393410625358084,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
17,O,O,rest,0.052216333891883446,0.04098345560197238,0.028988597607230784,0.033051989152861595,0.04721913895263862,0.054095619760174476,0.04220851874499575,0.030558322712437212,0.02402162710131033,0.020608164913000136,0.01882146186220746,0.017908434773749374,0.017512748391566624,0.017490012999071564,0.01782392024034913,0.018585504087041432,0.019909732587802462,0.021970970959791152,0.024920206353448073,0.028703230481552773,0.03268181710650293,0.03533381559383407,0.0350163629173102,0.03170786998648613,0.027057683703350075,0.02262893597894859,0.01906874277661031,0.016413834653791908,0.014494260270086321,0.013122185268372258,0.012145551044108076,0.011452197124789296,0.010961660394996756,0.01061639409304638,0.010375027141189043,0.010207653831832694,0.010092611966468545,0.010014250693663074,0.009961339415792069,0.009925899786771983,0.009902331033602102,0.009886750710464442,0.00987650059778831,0.009869781423634772,0.00986538761513412,0.009862518339363838,0.009860645356976892,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on 2021-03-11
Uses this POLYMOD duration data to deduce priors on the poisson
random variables controlling individual contact durations
@author: mark
"""
import numpy as np
import pandas as pd
import math
from itertools import product
# Read the cleaned survey as a dataframe
Contact = pd.read_csv("AALContact_data.csv")
# Specify AAL categories
Ages = ['Y', 'M', 'O']
SymAge = [('Y','Y'), ('Y', 'M'), ('Y', 'O'), ('M', 'M'),('M', 'O'), ('O','O')]
Locales = ['home', 'workschool', 'rest']
# define row function for symage
def symage_row(row):
agesrc = row['age_source']
agetar = row['age_target']
for symage in SymAge:
#x, y = symage[0], symage[1]
if symage == (agesrc, agetar) or symage == (agetar, agesrc):
return symage
Contact['symage'] = Contact.apply(symage_row, axis=1)
# Dictionary separating contact data by symage-location
ContAAL = {}
columns = ['part_id', 'cont_id', 'age_source', 'age_target',
'duration_multi', 'frequency_multi']
for symage, loc in list(product(SymAge,Locales)):
x,y,z = symage[0], symage[1], loc
C = Contact[Contact['cnt_'+z] == True][Contact['symage']==symage]
ContAAL[(x,y,z)] = C[columns].copy(deep=True)
# Duration distributions stratified by SymAge-location
DurFreqAAL = {}
for symage, loc in list(product(SymAge,Locales)):
x,y,z = symage[0], symage[1], loc
C = ContAAL[(x,y,z)]
Durlist = [C[C['duration_multi']==i]["duration_multi"].count() for i in range(1,6)]
DurFreqAAL[(x,y,z)] = Durlist/np.sum(Durlist)
# Define error functions for poisson random variables
durcutoff = {'home': 6*16, 'workschool': 6*8, 'rest': 6*8}
def PoisArray(lam, loc):
arr = [math.exp(-lam + k*math.log(lam) - np.sum([math.log(n) for n in range(1,k+1)]) )
for k in range(durcutoff[loc])]
return arr/np.sum(arr)
def PoisBin(lam,loc):
Arr = PoisArray(lam,loc)
out = [Arr[0], Arr[1], np.sum(Arr[2:6]), np.sum(Arr[6:24]), np.sum(Arr[24:])]
return out/np.sum(out)
def PoisErr(lam, label): # label is SymAge-Location
agesrc, agetar, loc = label
err = np.sum((PoisBin(lam, loc) - DurFreqAAL[label])**2)
return err
PoisErr = np.vectorize(PoisErr, excluded=[1])
PoisPrior={}
for symage, loc in list(product(SymAge, Locales)):
AAL = (symage[0],symage[1],loc)
arr = [1/PoisErr(i,AAL) for i in range(1,durcutoff[loc])]
zeropad = [0 for i in range(durcutoff['home'] - durcutoff[loc])]
PoisPrior[AAL] = (arr+zeropad)/np.sum(arr)
# Save them to csv
df = pd.DataFrame(list(PoisPrior.items()), columns=['col1','col2'])
dfkeys = pd.DataFrame([pd.Series(x) for x in df.col1])
dfkeys.columns = ["Age_in", "Age_out", "location"]
dfvals = pd.DataFrame([pd.Series(x) for x in df.col2])
dfout = dfkeys.join(dfvals)
dfout.to_csv("AALPoisPriors.csv")
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment