import json
import matplotlib.pyplot as plt
import numpy as np

fname = "UGC3816_f814w_completeness.json"

with open(fname) as fp:
    data = json.load(fp)

count = 500.
x, y, yerr = [], [], []
xx = []
for mag in data:
    xx.append(float(mag))
    x.append(np.median(data[mag]['mag']))
    y.append(np.median(data[mag]['count']) / count)
    yerr.append(np.std(data[mag]['count']) / count)

plt.clf()
# plt.plot(x, y, '.')
plt.plot(xx, y, '.')
plt.title(fname.split('.')[0])
plt.ylim(-0.1,1.1)
plt.grid()
plt.xlabel("magnitude")
plt.ylabel("completeness fraction")
1658503deefe2e255d371294e6ef847def11ae7a
<mask token>

<mask token>
with open(fname) as fp:
    data = json.load(fp)
<mask token>
for mag in data:
    xx.append(float(mag))
    x.append(np.median(data[mag]['mag']))
    y.append(np.median(data[mag]['count']) / count)
    yerr.append(np.std(data[mag]['count']) / count)
plt.clf()
plt.plot(xx, y, '.')
plt.title(fname.split('.')[0])
plt.ylim(-0.1, 1.1)
plt.grid()
plt.xlabel('magnitude')
plt.ylabel('completeness fraction')

<mask token>
fname = 'UGC3816_f814w_completeness.json'
with open(fname) as fp:
    data = json.load(fp)
count = 500.0
x, y, yerr = [], [], []
xx = []
for mag in data:
    xx.append(float(mag))
    x.append(np.median(data[mag]['mag']))
    y.append(np.median(data[mag]['count']) / count)
    yerr.append(np.std(data[mag]['count']) / count)
plt.clf()
plt.plot(xx, y, '.')
plt.title(fname.split('.')[0])
plt.ylim(-0.1, 1.1)
plt.grid()
plt.xlabel('magnitude')
plt.ylabel('completeness fraction')

import json
import matplotlib.pyplot as plt
import numpy as np
fname = 'UGC3816_f814w_completeness.json'
with open(fname) as fp:
    data = json.load(fp)
count = 500.0
x, y, yerr = [], [], []
xx = []
for mag in data:
    xx.append(float(mag))
    x.append(np.median(data[mag]['mag']))
    y.append(np.median(data[mag]['count']) / count)
    yerr.append(np.std(data[mag]['count']) / count)
plt.clf()
plt.plot(xx, y, '.')
plt.title(fname.split('.')[0])
plt.ylim(-0.1, 1.1)
plt.grid()
plt.xlabel('magnitude')
plt.ylabel('completeness fraction')

import json
import matplotlib.pyplot as plt
import numpy as np

fname = "UGC3816_f814w_completeness.json"

with open(fname) as fp:
    data = json.load(fp)

count = 500.
x, y, yerr = [], [], []
xx = []
for mag in data:
    xx.append(float(mag))
    x.append(np.median(data[mag]['mag']))
    y.append(np.median(data[mag]['count']) / count)
    yerr.append(np.std(data[mag]['count']) / count)

plt.clf()
# plt.plot(x, y, '.')
plt.plot(xx, y, '.')
plt.title(fname.split('.')[0])
plt.ylim(-0.1,1.1)
plt.grid()
plt.xlabel("magnitude")
plt.ylabel("completeness fraction")