DOI-USGS / water-use

Visualization using USGS water use data.
https://owi.usgs.gov/vizlab/water-use/
Creative Commons Zero v1.0 Universal
15 stars 16 forks source link

spot-check sizes (px count) to scaling and numbers #174

Closed jordansread closed 7 years ago

jordansread commented 7 years ago

Verify that the colored pixel count within a state scales appropriately and that states are comparable.

jordansread commented 7 years ago
1995: ---
CA: 35294 mgd
    42088 pixels of color #2e86ab
    [0.8386 mgd per pixel]
TX: 24629 mgd
    29231 pixels of color #2e86ab
    [0.8426 mgd per pixel]
IL: 19547 mgd
    23301 pixels of color #2e86ab
    [0.8389 mgd per pixel]
NJ: 2137 mgd
    2448 pixels of color #2e86ab
    [0.8729 mgd per pixel]

1980: ---
CA: 43555 mgd
    52009 pixels of color #2e86ab
    [0.8375 mgd per pixel]
TX: 13958 mgd
    16511 pixels of color #2e86ab
    [0.8454 mgd per pixel]
IL: 17704 mgd
    2108 pixels of color #2e86ab
    [0.8396 mgd per pixel]
NJ: 2790 mgd
    3222 pixels of color #2e86ab
    [0.8659 mgd per pixel]

using

convert ../count_px/1980/NJ.png -format %c histogram:info:-

which outputs:

      3222: ( 46,134,171,255) #2E86ABFF srgba(46,134,171,1)
        43: ( 70,147,180,255) #4693B4FF srgba(70,147,180,1)
         1: ( 72,149,181,255) #4895B5FF srgba(72,149,181,1)
         2: ( 88,154,182,255) #589AB6FF srgba(88,154,182,1)
        28: ( 95,161,188,255) #5FA1BCFF srgba(95,161,188,1)
         1: ( 98,164,192,255) #62A4C0FF srgba(98,164,192,1)
         1: (107,162,185,255) #6BA2B9FF srgba(107,162,185,1)
        47: (119,174,197,255) #77AEC5FF srgba(119,174,197,1)
         1: (124,179,202,255) #7CB3CAFF srgba(124,179,202,1)
         2: (135,179,198,255) #87B3C6FF srgba(135,179,198,1)
         1: (140,184,203,255) #8CB8CBFF srgba(140,184,203,1)
        38: (143,187,206,255) #8FBBCEFF srgba(143,187,206,1)
         1: (149,182,196,255) #95B6C4FF srgba(149,182,196,1)
         1: (150,194,213,255) #96C2D5FF srgba(150,194,213,1)
         1: (153,186,200,255) #99BAC8FF srgba(153,186,200,1)
         1: (164,197,211,255) #A4C5D3FF srgba(164,197,211,1)
         1: (166,199,213,255) #A6C7D5FF srgba(166,199,213,1)
        37: (168,201,215,255) #A8C9D7FF srgba(168,201,215,1)
         1: (169,191,201,255) #A9BFC9FF srgba(169,191,201,1)
         1: (176,198,207,255) #B0C6CFFF srgba(176,198,207,1)
         1: (177,210,223,255) #B1D2DFFF srgba(177,210,223,1)
         1: (180,202,211,255) #B4CAD3FF srgba(180,202,211,1)
        45: (192,214,223,255) #C0D6DFFF srgba(192,214,223,1)
         1: (192,214,224,255) #C0D6E0FF srgba(192,214,224,1)
         1: (197,208,212,255) #C5D0D4FF srgba(197,208,212,1)
         1: (203,225,234,255) #CBE1EAFF srgba(203,225,234,1)
         1: (205,216,220,255) #CDD8DCFF srgba(205,216,220,1)
         1: (208,208,208,255) #D0D0D0FF srgba(208,208,208,1)
         1: (208,219,223,255) #D0DBDFFF srgba(208,219,223,1)
         1: (209,220,224,255) #D1DCE0FF srgba(209,220,224,1)
         2: (210,210,210,255) #D2D2D2FF srgba(210,210,210,1)
        16: (211,211,211,255) #D3D3D3FF LightGray
         9: (212,212,212,255) #D4D4D4FF grey83
         5: (213,213,213,255) #D5D5D5FF srgba(213,213,213,1)
         2: (213,224,228,255) #D5E0E4FF srgba(213,224,228,1)
        12: (214,214,214,255) #D6D6D6FF grey84
        30: (215,215,215,255) #D7D7D7FF srgba(215,215,215,1)
         3: (216,216,216,255) #D8D8D8FF srgba(216,216,216,1)
        25: (217,217,217,255) #D9D9D9FF grey85
        45: (217,228,232,255) #D9E4E8FF srgba(217,228,232,1)
        32: (218,218,218,255) #DADADAFF srgba(218,218,218,1)
         3: (219,219,219,255) #DBDBDBFF grey86
         4: (220,220,220,255) #DCDCDCFF gainsboro
         9: (221,221,221,255) #DDDDDDFF srgba(221,221,221,1)
        22: (222,222,222,255) #DEDEDEFF grey87
        18: (223,223,223,255) #DFDFDFFF srgba(223,223,223,1)
         8: (224,224,224,255) #E0E0E0FF grey88
        24: (225,225,225,255) #E1E1E1FF srgba(225,225,225,1)
        14: (226,226,226,255) #E2E2E2FF srgba(226,226,226,1)
         4: (227,227,227,255) #E3E3E3FF grey89
         4: (228,228,228,255) #E4E4E4FF srgba(228,228,228,1)
        55: (229,229,229,255) #E5E5E5FF grey90
         1: (231,231,231,255) #E7E7E7FF srgba(231,231,231,1)
         1: (232,232,232,255) #E8E8E8FF grey91
        32: (233,233,233,255) #E9E9E9FF srgba(233,233,233,1)
        31: (234,234,234,255) #EAEAEAFF srgba(234,234,234,1)
        26: (237,237,237,255) #EDEDEDFF grey93
         2: (239,239,239,255) #EFEFEFFF srgba(239,239,239,1)
        34: (240,240,240,255) #F0F0F0FF grey94
      4627: (241,241,241,255) #F1F1F1FF srgba(241,241,241,1)
         1: (243,243,243,255) #F3F3F3FF srgba(243,243,243,1)
         1: (244,244,244,255) #F4F4F4FF srgba(244,244,244,1)
        27: (245,245,245,255) #F5F5F5FF grey96
         2: (248,248,248,255) #F8F8F8FF srgba(248,248,248,1)
        54: (250,250,250,255) #FAFAFAFF grey98
      3542: (255,255,255,255) #FFFFFFFF white
jordansread commented 7 years ago

explanation of the above ☝️ I took png images of the viz with other states masked out and at the same zoom level. There are 4 colors in the map - white, grey (state background), darker grey (state background border), and the emphasis color (http://www.color-hex.com/color/2e86ab). I used imagemagick to do histograms of the images for each state to get a pixel count for each color. There are way more than 4 colors coming back in the histograms, which is because of the edges. So, it makes sense that the ratios of px to mgd will vary a bit among more complex features, and that the smaller the size of the emphasis space, the more "border" pixels you have which drops the px count for the emphasis color.

jordansread commented 7 years ago

completed