In [1]:
from __future__ import print_function, division

import nsfg3

In [2]:
df = nsfg3.ReadFemResp2010()
len(df)


Out[2]:
12279

In [3]:
df.evrmarry.value_counts()


Out[3]:
0    6745
1    5534
Name: evrmarry, dtype: int64

In [4]:
len(df[(df.cmbirth >= 522) & (df.cmbirth <= 1278)])


Out[4]:
12279

In [5]:
len(df[(df.cmmarrhx >= 522) & (df.cmmarrhx <= 1278)])


Out[5]:
4988

In [6]:
len(df[(df.cmmarrhx.isnull())])


Out[6]:
6759

In [7]:
df.cmintvw.value_counts().sort_index()


Out[7]:
1278     52
1279    332
1280    266
1281    194
1282    367
1283    356
1284     74
1285    289
1286    283
1287    199
1288    280
1289    317
1290     97
1291    244
1292    311
1293    198
1294    289
1295    243
1296     60
1297    243
1298    249
1299    195
1300    275
1301    303
1302    151
1303    328
1304    257
1305    197
1306    285
1307    296
1308    126
1309    270
1310    307
1311    269
1312    302
1313    342
1314    163
1315    239
1316    290
1317    255
1318    306
1319    345
1320    145
1321    329
1322    266
1323    255
1324    339
1325    356
1326    145
Name: cmintvw, dtype: int64

In [8]:
df.finalwgt.value_counts().sort_index()


Out[8]:
41.084436        1
44.023984        1
49.264753        1
50.253080        1
51.762820        1
54.007121        1
54.326404        1
54.787230        1
55.641206        1
57.502150        1
58.094969        1
58.097193        1
58.918388        1
59.728322        1
63.288633        1
64.839626        1
64.976180        1
65.381502        1
65.816954        1
66.207563        1
67.406247        1
68.378722        1
69.122460        1
69.272292        1
72.566655        1
73.265318        1
73.550226        1
73.822704        1
73.907262        1
73.957456        1
                ..
26045.499512    50
26123.574277     1
26218.172271     1
26285.859569     1
26306.399047     1
26315.507259     1
26410.855828     1
26449.973578     1
26557.324114     1
26618.050695     1
26635.647358     1
26652.286657     1
26718.649136     1
26825.183831     1
26951.040017     1
27069.679720     1
27141.949282     6
27141.949282    47
27141.949282     2
27142.397101    44
27324.994998     1
27745.599707     1
27928.880798     1
28202.105357     1
28213.094904     1
28420.871454     1
29007.582235     1
29455.053780     1
30226.354508    38
30226.354508    17
Name: finalwgt, dtype: int64

In [ ]:


In [ ]: