This is a dataset of Assisted Living, Nursing and Residential Care facilities in Oregon, open as of January, 2017. For each, we have:

  1. facility_id: Unique ID used to join to complaints
  2. fac_ccmunumber: Unique ID used to join to ownership history
  3. facility_type: NF - Nursing Facility; RCF - Residential Care Facility; ALF - Assisted Living Facility
  4. fac_capacity: Number of beds facility is licensed to have. Not necessarily the number of beds facility does have.
  5. offline: created in munging notebook, a count of complaints that DO NOT appear when facility is searched on state's complaint search website (https://apps.state.or.us/cf2/spd/facility_complaints/).
  6. online: created in munging notebook, a count of complaints that DO appear when facility is searched on state's complaint search website (https://apps.state.or.us/cf2/spd/facility_complaints/).

In [32]:
import pandas as pd
import numpy as np
from IPython.core.display import display, HTML
display(HTML("<style>.container { width:100% !important; }</style>"))



In [33]:
df = pd.read_csv('../../data/processed/facilities-before-state-updates.csv')

How many facilities have accurate records online?

Those that have no offline records.


In [34]:
df[(df['offline'].isnull())].count()[0]


Out[34]:
57

How many facilities have inaccurate records online?<h/3>

Those that have offline records.


In [35]:
df[(df['offline'].notnull())].count()[0]


Out[35]:
585

How many facilities had more than double the number of complaints shown online?


In [36]:
df[(df['offline']>df['online']) & (df['online'].notnull())].count()[0]


Out[36]:
357

How many facilities show zero complaints online but have complaints offline?


In [37]:
df[(df['online'].isnull()) & (df['offline'].notnull())].count()[0]


Out[37]:
59

How many facilities have complaints and are accurate online?


In [38]:
df[(df['online'].notnull()) & (df['offline'].isnull())].count()[0]


Out[38]:
14

How many facilities have complaints?


In [39]:
df[(df['online'].notnull()) | df['offline'].notnull()].count()[0]


Out[39]:
599

What percent of facilities have accurate records online?


In [40]:
df[(df['offline'].isnull())].count()[0]/df.count()[0]*100


Out[40]:
8.8785046728971952

What is the total capacity of all facilities with inaccurate records?


In [41]:
df[df['offline'].notnull()].sum()['fac_capacity']


Out[41]:
35238.0

In [42]:
df[df['facility_name'].str.contains('Springfield')]


Out[42]:
facility_id fac_ccmunumber facility_type fac_capacity facility_name offline online
16 385077 385077 NF 136.0 Marquis Springfield 30.0 7.0
473 70A299 70A299 ALF 150.0 Brookdale Springfield Briarwood 43.0 47.0
611 70M226 70M226 ALF 62.0 Brookdale Springfield Woodside 24.0 7.0

In [44]:
df[(df['online'].isnull())].sort_values('offline',ascending=False)


Out[44]:
facility_id fac_ccmunumber facility_type fac_capacity facility_name offline online
117 385275 385275 NF 51.0 Sheridan Care Center 32.0 NaN
359 50R408 50R408 RCF 15.0 Bee Hive Homes of Baker City 15.0 NaN
337 50R385 50R385 RCF 24.0 Bonaventure of Salem Memory Care 14.0 NaN
483 70A309 70A309 ALF 65.0 Hawthorne Gardens Senior Living Community 12.0 NaN
493 70A320 70A320 ALF 65.0 Bonaventure of Salem Assisted Living 12.0 NaN
495 70A322 70A322 ALF 19.0 Wallowa Valley Senior Living 11.0 NaN
56 385181 385181 NF 20.0 East Cascade Retirement Community, LLC 10.0 NaN
507 70M010 70M010 ALF 45.0 Brookside Place 10.0 NaN
193 50M300 50M300 RCF 44.0 Quail Park Memory Care Residences of Klamath F... 9.0 NaN
335 50R383 50R383 RCF 28.0 Royalton Place Memory Care 9.0 NaN
351 50R400 50R400 RCF 15.0 Vista View Mood & Memory Care 8.0 NaN
317 50R365 NaN RCF 108.0 Churchill Estates Residential Care 8.0 NaN
91 385237 385237 NF 63.0 Fernhill Estates 7.0 NaN
342 50R390 50R390 RCF 56.0 Mt. Bachelor Memory Care 7.0 NaN
365 50R414 50R414 RCF 48.0 Arbor at Avamere Court, The 5.0 NaN
494 70A321 70A321 ALF 25.0 Dallas Retirement Village Assisted Living HUD 4.0 NaN
353 50R402 50R402 RCF 18.0 Grace Manor 4.0 NaN
360 50R409 50R409 RCF 48.0 Heartwood Place 4.0 NaN
363 50R412 50R412 RCF 16.0 Sunset Estates 4.0 NaN
367 50R417 50R417 RCF 34.0 Advocate Care 4.0 NaN
134 38L503 38L503 NF 154.0 Lebanon Veterans Home 4.0 NaN
492 70A319 70A319 ALF 64.0 Royalton Place Assisted Living 4.0 NaN
354 50R403 50R403 RCF 44.0 Brookdale Geary Street Memory Care 3.0 NaN
496 70A323 70A323 ALF 101.0 Waterford Grand Assisted Living 3.0 NaN
378 5MA043 5MA043 RCF 102.0 Providence ElderPlace in Glendoveer 3.0 NaN
588 70M103 70M103 ALF 60.0 Wiley Creek Community 3.0 NaN
234 50R229 50R229 RCF 96.0 Willamette View Terrace 3.0 NaN
130 38E196 38E196 NF 41.0 Lawrence Convalescent Center 3.0 NaN
321 50R369 50R369 RCF 40.0 Hillside Care Manor 3.0 NaN
283 50R321 50R321 RCF 42.0 Providence ElderPlace in Cully 3.0 NaN
... ... ... ... ... ... ... ...
235 50R230 50R230 RCF 44.0 Holladay Park Plaza NaN NaN
241 50R273 50R273 RCF 27.0 Suttle Care & Retirement NaN NaN
278 50R315 50R315 RCF 16.0 All Comfort Residential Care NaN NaN
336 50R384 50R384 RCF 20.0 Senior Haven Residential Care Facility NaN NaN
338 50R386 50R386 RCF 7.0 Thanksgiving House NaN NaN
339 50R387 50R387 RCF 13.0 Griffin House, The NaN NaN
340 50R388 50R388 RCF 10.0 Gateway 2 Healthier Living NaN NaN
345 50R394 50R394 RCF 10.0 Valley View Memory Care NaN NaN
347 50R396 50R396 RCF 39.0 Whitewood Gardens NaN NaN
348 50R397 50R397 RCF 31.0 Footsteps at Sherwood NaN NaN
349 50R398 50R398 RCF 16.0 Footsteps at Carman Oaks NaN NaN
350 50R399 50R399 RCF 25.0 Footsteps at Mill Creek NaN NaN
356 50R405 50R405 RCF 15.0 Elite Care Oatfield Estates Larch House NaN NaN
357 50R406 50R406 RCF 15.0 Elite Care Oatfield Estates Tabor House NaN NaN
361 50R410 50R410 RCF 21.0 McKenzie Living NaN NaN
362 50R411 50R411 RCF 64.0 Waterford Grand Memory Care NaN NaN
368 50R418 50R418 RCF 64.0 Windsong at Eola Hills NaN NaN
369 50R421 50R421 RCF 32.0 Clatsop Care Memory Community NaN NaN
370 50R430 50R430 RCF 23.0 Bonaventure of Albany Memory Care NaN NaN
371 50R432 50R432 RCF 23.0 Bonaventure of Tigard Memory Care NaN NaN
372 50R433 50R433 RCF 68.0 Waterhouse Ridge Memory Care Community NaN NaN
423 70A057 70A057 ALF 63.0 Markham House Retirement Community NaN NaN
427 70A097 70A097 ALF 70.0 Timberhill Place NaN NaN
432 70A235 70A235 ALF 60.0 Bonaventure of Albany Assisted Living NaN NaN
434 70A249 70A249 ALF 20.0 Providence Brookside Manor NaN NaN
474 70A300 70A300 ALF 44.0 Springs at Veranda Park, The NaN NaN
475 70A301 70A301 ALF 69.0 Bonaventure of Tigard Assisted Living NaN NaN
490 70A317 70A317 ALF 24.0 Mirabella at South Waterfront NaN NaN
491 70A318 70A318 ALF 22.0 Countryside Village NaN NaN
640 70M350 70M350 ALF 119.0 Village at Keizer Ridge, The NaN NaN

102 rows × 7 columns


In [46]:
df[df['online'].isnull()].count()


Out[46]:
facility_id       102
fac_ccmunumber    101
facility_type     102
fac_capacity      102
facility_name     102
offline            59
online              0
dtype: int64

In [47]:
df[(df['online'].isnull()) & (df['offline'].notnull())].count()


Out[47]:
facility_id       59
fac_ccmunumber    58
facility_type     59
fac_capacity      59
facility_name     59
offline           59
online             0
dtype: int64

In [48]:
df[(df['online'].isnull()) & (df['offline'].isnull())].count()


Out[48]:
facility_id       43
fac_ccmunumber    43
facility_type     43
fac_capacity      43
facility_name     43
offline            0
online             0
dtype: int64

In [50]:
df[df['offline'].isnull()].count()


Out[50]:
facility_id       57
fac_ccmunumber    57
facility_type     57
fac_capacity      57
facility_name     57
offline            0
online            14
dtype: int64

In [ ]: