Dataset histogram
The Dataset histogram view describes the distribution of values in a dataset.
Use it to inspect categorical frequencies, numeric bins, target statistics, and masked or infrequent values before training, model review, or explanation work.
When to use
| Use case | Description |
|---|---|
| Inspect data distribution | Review how feature and target values are distributed across the dataset. |
| Check categorical balance | Compare category frequencies and frequency fractions for categorical fields. |
| Review numeric bins | Inspect bin ranges and frequencies for numeric fields. |
| Investigate target behaviour | Use target summary statistics to understand how target values vary across bins or categories. |
| Focus on selected fields | Use fields to return histogram data for specific dataset fields. |
Generate the view
Generate the Dataset histogram view from a dataset.
{"data": [{"view_type": "HISTOGRAM","output_version": {"major_version": 1,"minor_version": 1,"patch_version": 1},"view_data": {"columns": ["bin_index","bin_low","bin_high","token","field_type","is_categorical","frequency","target_min","target_max","target_mean","target_sum","target_var","target_stddev","frequency_fraction","is_masked_token","is_infrequent","field"],"index": [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,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112],"data": [[0,0,0,"10th","FEATURE",true,1950,[0],[1],[0.0594871795],[116],[0.055948455],[0.2365342575],0.0278547553,false,false,"education"],[0,0,0,"11th","FEATURE",true,2499,[0],[1],[0.0496198479],[124],[0.0471577186],[0.2171582801],0.0356969403,false,false,"education"],[0,0,0,"12th","FEATURE",true,929,[0],[1],[0.0656620022],[61],[0.0613505036],[0.2476903382],0.0132702911,false,false,"education"],[0,0,0,"1st-4th","FEATURE",true,374,[0],[1],[0.0294117647],[11],[0.0285467128],[0.1689577249],0.0053423992,false,false,"education"],[0,0,0,"5th-6th","FEATURE",true,758,[0],[1],[0.0540897098],[41],[0.0511640131],[0.2261946353],0.0108276433,false,false,"education"],[0,0,0,"7th-8th","FEATURE",true,1363,[0],[1],[0.0652971387],[89],[0.0610334223],[0.247049433],0.0194697597,false,false,"education"],[0,0,0,"9th","FEATURE",true,1087,[0],[1],[0.0441582337],[48],[0.0422082841],[0.205446548],0.0155272405,false,false,"education"],[0,0,0,"Assoc-acdm","FEATURE",true,2194,[0],[1],[0.2525068368],[554],[0.1887471342],[0.4344503817],0.0313401708,false,false,"education"],[0,0,0,"Assoc-voc","FEATURE",true,2845,[0],[1],[0.2358523726],[671],[0.1802260309],[0.4245303651],0.0406393738,false,false,"education"],[0,0,0,"Bachelors","FEATURE",true,10936,[0],[1],[0.404444038],[4423],[0.2408690581],[0.4907841258],0.1562151816,false,false,"education"],[0,0,0,"Doctorate","FEATURE",true,801,[0],[1],[0.7116104869],[570],[0.2052210018],[0.4530132469],0.0114418764,false,false,"education"],[0,0,0,"HS-grad","FEATURE",true,21970,[0],[1],[0.1511606736],[3321],[0.1283111244],[0.3582054221],0.3138302431,false,false,"education"],[0,0,0,"Masters","FEATURE",true,3626,[0],[1],[0.5383342526],[1952],[0.2485304851],[0.4985283192],0.0517955604,false,false,"education"],[0,0,0,"Preschool","FEATURE",true,117,[0],[1],[0.0085470085],[1],[0.0084739572],[0.0920540993],0.0016712853,false,false,"education"],[0,0,0,"Prof-school","FEATURE",true,1116,[0],[1],[0.7419354839],[828],[0.1914672216],[0.4375696763],0.0159414907,false,false,"education"],[0,0,0,"Some-college","FEATURE",true,15265,[0],[1],[0.1816573862],[2773],[0.1486579802],[0.3855619019],0.2180527383,false,false,"education"],[0,0,0,"__MASK__","FEATURE",true,2176,[0],[1],[0.2329963235],[507],[0.1787090368],[0.4228370866],0.03108305,true,false,"education"],[0,0,0,"Female","FEATURE",true,22198,[0],[1],[0.1159113434],[2573],[0.1024759038],[0.3201185778],0.3170871068,false,false,"gender"],[0,0,0,"Male","FEATURE",true,41938,[0],[1],[0.2931708713],[12295],[0.2072217115],[0.4552161152],0.5990629375,false,false,"gender"],[0,0,0,"__MASK__","FEATURE",true,5870,[0],[1],[0.2081771721],[1222],[0.1648394371],[0.4060388203],0.0838499557,true,false,"gender"],[0,0,0,"0","TARGET",true,53916,[0],[0],[0],[0],[0],[0],0.7701625575,false,false,"income"],[0,0,0,"1","TARGET",true,16090,[1],[1],[1],[16090],[0],[0],0.2298374425,false,false,"income"],[0,0,0,"Divorced","FEATURE",true,9511,[0],[1],[0.0990432131],[942],[0.0892336551],[0.2987200279],0.1358597834,false,false,"marital_45_status"],[0,0,0,"Married-AF-spouse","FEATURE",true,54,[0],[1],[0.4074074074],[22],[0.2414266118],[0.4913518208],0.0007713625,false,false,"marital_45_status"],[0,0,0,"Married-civ-spouse","FEATURE",true,30696,[0],[1],[0.4401224915],[13510],[0.246414684],[0.4964017365],0.438476702,false,false,"marital_45_status"],[0,0,0,"Married-spouse-absent","FEATURE",true,970,[0],[1],[0.0855670103],[83],[0.0782452971],[0.2797236083],0.0138559552,false,false,"marital_45_status"],[0,0,0,"Never-married","FEATURE",true,23163,[0],[1],[0.0441652636],[1023],[0.0422146931],[0.2054621451],0.3308716396,false,false,"marital_45_status"],[0,0,0,"Separated","FEATURE",true,2237,[0],[1],[0.0621367903],[139],[0.0582758096],[0.241403831],0.0319544039,false,false,"marital_45_status"],[0,0,0,"Widowed","FEATURE",true,2266,[0],[1],[0.0820829656],[186],[0.0753453523],[0.2744910788],0.0323686541,false,false,"marital_45_status"],[0,0,0,"__MASK__","FEATURE",true,1109,[0],[1],[0.1668169522],[185],[0.1389890567],[0.3729805599],0.0158414993,true,false,"marital_45_status"],[0,0,0,"?","FEATURE",true,1261,[0],[1],[0.2394924663],[302],[0.1821358249],[0.4267737397],0.0180127418,false,false,"native_45_country"],[0,0,0,"Cambodia","FEATURE",true,40,[0],[1],[0.3],[12],[0.21],[0.4582575695],0.0005713796,false,false,"native_45_country"],[0,0,0,"Canada","FEATURE",true,263,[0],[1],[0.36121673],[95],[0.230739204],[0.4803532075],0.0037568208,false,false,"native_45_country"],[0,0,0,"China","FEATURE",true,196,[0],[1],[0.3010204082],[59],[0.210407122],[0.458701561],0.00279976,false,false,"native_45_country"],[0,0,0,"Columbia","FEATURE",true,134,[0],[1],[0.052238806],[7],[0.0495099131],[0.2225082316],0.0019141216,false,false,"native_45_country"],[0,0,0,"Cuba","FEATURE",true,217,[0],[1],[0.2211981567],[48],[0.1722695322],[0.4150536497],0.0030997343,false,false,"native_45_country"],[0,0,0,"Dominican-Republic","FEATURE",true,165,[0],[1],[0.0484848485],[8],[0.046134068],[0.214788426],0.0023569408,false,false,"native_45_country"],[0,0,0,"Ecuador","FEATURE",true,76,[0],[1],[0.1052631579],[8],[0.0941828255],[0.306892205],0.0010856212,false,false,"native_45_country"],[0,0,0,"El-Salvador","FEATURE",true,253,[0],[1],[0.0513833992],[13],[0.0487431455],[0.2207784987],0.0036139759,false,false,"native_45_country"],[0,0,0,"England","FEATURE",true,170,[0],[1],[0.3705882353],[63],[0.2332525952],[0.4829623124],0.0024283633,false,false,"native_45_country"],[0,0,0,"France","FEATURE",true,58,[0],[1],[0.4310344828],[25],[0.2452437574],[0.4952209178],0.0008285004,false,false,"native_45_country"],[0,0,0,"Germany","FEATURE",true,298,[0],[1],[0.2953020134],[88],[0.2080987343],[0.4561784018],0.004256778,false,false,"native_45_country"],[0,0,0,"Greece","FEATURE",true,66,[0],[1],[0.3181818182],[21],[0.2169421488],[0.4657704894],0.0009427763,false,false,"native_45_country"],[0,0,0,"Guatemala","FEATURE",true,154,[0],[1],[0.0194805195],[3],[0.0191010288],[0.1382064718],0.0021998114,false,false,"native_45_country"],[0,0,0,"Haiti","FEATURE",true,118,[0],[1],[0.1355932203],[16],[0.1172076989],[0.3423560996],0.0016855698,false,false,"native_45_country"],[0,0,0,"Holand-Netherlands","FEATURE",true,1,[0],[0],[0],[0],[0],[0],0.0000142845,false,true,"native_45_country"],[0,0,0,"Honduras","FEATURE",true,30,[0],[1],[0.0666666667],[2],[0.0622222222],[0.2494438258],0.0004285347,false,false,"native_45_country"],[0,0,0,"Hong","FEATURE",true,53,[0],[1],[0.2452830189],[13],[0.1851192595],[0.4302548774],0.000757078,false,false,"native_45_country"],[0,0,0,"Hungary","FEATURE",true,29,[0],[1],[0.3103448276],[9],[0.2140309156],[0.462634754],0.0004142502,false,false,"native_45_country"],[0,0,0,"India","FEATURE",true,222,[0],[1],[0.3738738739],[83],[0.2340922003],[0.4838307559],0.0031711568,false,false,"native_45_country"],[0,0,0,"Iran","FEATURE",true,83,[0],[1],[0.3493975904],[29],[0.2273189142],[0.4767797334],0.0011856127,false,false,"native_45_country"],[0,0,0,"Ireland","FEATURE",true,49,[0],[1],[0.2857142857],[14],[0.2040816327],[0.4517539515],0.00069994,false,false,"native_45_country"],[0,0,0,"Italy","FEATURE",true,152,[0],[1],[0.3421052632],[52],[0.2250692521],[0.4744146415],0.0021712425,false,false,"native_45_country"],[0,0,0,"Jamaica","FEATURE",true,170,[0],[1],[0.1529411765],[26],[0.129550173],[0.3599307892],0.0024283633,false,false,"native_45_country"],[0,0,0,"Japan","FEATURE",true,138,[0],[1],[0.3913043478],[54],[0.2381852552],[0.4880422678],0.0019712596,false,false,"native_45_country"],[0,0,0,"Laos","FEATURE",true,41,[0],[1],[0.0487804878],[2],[0.0464009518],[0.2154088016],0.0005856641,false,false,"native_45_country"],[0,0,0,"Mexico","FEATURE",true,1587,[0],[1],[0.0441083806],[70],[0.0421628314],[0.2053358988],0.0226694855,false,false,"native_45_country"],[0,0,0,"Nicaragua","FEATURE",true,77,[0],[1],[0.0519480519],[4],[0.0492494518],[0.2219221752],0.0010999057,false,false,"native_45_country"],[0,0,0,"Outlying-US(Guam-USVI-etc)","FEATURE",true,30,[0],[1],[0.0333333333],[1],[0.0322222222],[0.1795054936],0.0004285347,false,false,"native_45_country"],[0,0,0,"Peru","FEATURE",true,75,[0],[1],[0.08],[6],[0.0736],[0.2712931993],0.0010713367,false,false,"native_45_country"],[0,0,0,"Philippines","FEATURE",true,495,[0],[1],[0.2767676768],[137],[0.2001673299],[0.4474006369],0.0070708225,false,false,"native_45_country"],[0,0,0,"Poland","FEATURE",true,127,[0],[1],[0.1732283465],[22],[0.1432202864],[0.3784445619],0.0018141302,false,false,"native_45_country"],[0,0,0,"Portugal","FEATURE",true,102,[0],[1],[0.1764705882],[18],[0.1453287197],[0.3812200411],0.001457018,false,false,"native_45_country"],[0,0,0,"Puerto-Rico","FEATURE",true,286,[0],[1],[0.1048951049],[30],[0.0938921219],[0.306418214],0.0040853641,false,false,"native_45_country"],[0,0,0,"Scotland","FEATURE",true,31,[0],[1],[0.1290322581],[4],[0.1123829344],[0.3352356402],0.0004428192,false,false,"native_45_country"],[0,0,0,"South","FEATURE",true,181,[0],[1],[0.1878453039],[34],[0.1525594457],[0.3905885888],0.0025854927,false,false,"native_45_country"],[0,0,0,"Taiwan","FEATURE",true,100,[0],[1],[0.36],[36],[0.2304],[0.48],0.001428449,false,false,"native_45_country"],[0,0,0,"Thailand","FEATURE",true,56,[0],[1],[0.2142857143],[12],[0.1683673469],[0.4103259033],0.0007999314,false,false,"native_45_country"],[0,0,0,"Trinadad&Tobago","FEATURE",true,43,[0],[1],[0.0465116279],[2],[0.0443482964],[0.210590352],0.0006142331,false,false,"native_45_country"],[0,0,0,"United-States","FEATURE",true,61883,[0],[1],[0.2357351777],[14588],[0.1801641037],[0.4244574227],0.8839670885,false,false,"native_45_country"],[0,0,0,"Vietnam","FEATURE",true,134,[0],[1],[0.0746268657],[10],[0.0690576966],[0.2627883114],0.0019141216,false,false,"native_45_country"],[0,0,0,"Yugoslavia","FEATURE",true,33,[0],[1],[0.3333333333],[11],[0.2222222222],[0.4714045208],0.0004713882,false,false,"native_45_country"],[0,0,0,"__MASK__","FEATURE",true,329,[0],[1],[0.1610942249],[53],[0.1351428756],[0.3681778057],0.0046995972,true,false,"native_45_country"],[0,0,0,"__INFREQUENT__","FEATURE",true,1,[0],[0],[0],[0],[0],[0],0,true,false,"native_45_country"],[0,0,0,"?","FEATURE",true,4077,[0],[1],[0.0892813343],[364],[0.0813101777],[0.2851493953],0.0582378653,false,false,"occupation"],[0,0,0,"Adm-clerical","FEATURE",true,7758,[0],[1],[0.1318638824],[1023],[0.114475799],[0.3383427241],0.1108190727,false,false,"occupation"],[0,0,0,"Armed-Forces","FEATURE",true,19,[0],[1],[0.3684210526],[7],[0.2326869806],[0.4823763889],0.0002714053,false,false,"occupation"],[0,0,0,"Craft-repair","FEATURE",true,7847,[0],[1],[0.2197017969],[1724],[0.1714329173],[0.4140445837],0.1120903923,false,false,"occupation"],[0,0,0,"Exec-managerial","FEATURE",true,7970,[0],[1],[0.4681304893],[3731],[0.2489843343],[0.4989833006],0.1138473845,false,false,"occupation"],[0,0,0,"Farming-fishing","FEATURE",true,1994,[0],[1],[0.1088264794],[217],[0.0969832768],[0.3114213814],0.0284832729,false,false,"occupation"],[0,0,0,"Handlers-cleaners","FEATURE",true,2710,[0],[1],[0.0612546125],[166],[0.057502485],[0.2397967577],0.0387109676,false,false,"occupation"],[0,0,0,"Machine-op-inspct","FEATURE",true,4016,[0],[1],[0.1118027888],[449],[0.0993029253],[0.3151236666],0.0573665114,false,false,"occupation"],[0,0,0,"Other-service","FEATURE",true,6854,[0],[1],[0.0398307558],[273],[0.0382442667],[0.195561414],0.0979058938,false,false,"occupation"],[0,0,0,"Priv-house-serv","FEATURE",true,380,[0],[1],[0.0131578947],[5],[0.0129847645],[0.113950711],0.0054281062,false,false,"occupation"],[0,0,0,"Prof-specialty","FEATURE",true,8463,[0],[1],[0.450667612],[3814],[0.2475663155],[0.4975603637],0.120889638,false,false,"occupation"],[0,0,0,"Protective-serv","FEATURE",true,1282,[0],[1],[0.3042121685],[390],[0.211667125],[0.4600729562],0.0183127161,false,false,"occupation"],[0,0,0,"Sales","FEATURE",true,7212,[0],[1],[0.2534664448],[1828],[0.1892212062],[0.4349956393],0.1030197412,false,false,"occupation"],[0,0,0,"Tech-support","FEATURE",true,1939,[0],[1],[0.2841670964],[551],[0.2034161577],[0.4510168043],0.0276976259,false,false,"occupation"],[0,0,0,"Transport-moving","FEATURE",true,2975,[0],[1],[0.2],[595],[0.16],[0.4],0.0424963575,false,false,"occupation"],[0,0,0,"__MASK__","FEATURE",true,4510,[0],[1],[0.211308204],[953],[0.1666570469],[0.4082817751],0.0644230495,true,false,"occupation"],[0,0,0,"Amer-Indian-Eskimo","FEATURE",true,693,[0],[1],[0.1183261183],[82],[0.104325048],[0.3229938824],0.0098991515,false,false,"race"],[0,0,0,"Asian-Pac-Islander","FEATURE",true,2278,[0],[1],[0.2572431958],[586],[0.191069134],[0.4371145548],0.032540068,false,false,"race"],[0,0,0,"Black","FEATURE",true,6889,[0],[1],[0.1154013645],[795],[0.1020838896],[0.3195056957],0.0984058509,false,false,"race"],[0,0,0,"Other","FEATURE",true,654,[0],[1],[0.1177370031],[77],[0.1038750012],[0.3222964492],0.0093420564,false,false,"race"],[0,0,0,"White","FEATURE",true,58592,[0],[1],[0.2456137357],[14391],[0.1852876285],[0.4304504949],0.8369568323,false,false,"race"],[0,0,0,"__MASK__","FEATURE",true,900,[0],[1],[0.1766666667],[159],[0.1454555556],[0.381598418],0.0128560409,true,false,"race"],[0,0,0,"Husband","FEATURE",true,25550,[0],[1],[0.4444227006],[11355],[0.2469111638],[0.4969015635],0.364968717,false,false,"relationship"],[0,0,0,"Not-in-family","FEATURE",true,17179,[0],[1],[0.1016939286],[1747],[0.0913522735],[0.3022453863],0.245393252,false,false,"relationship"],[0,0,0,"Other-relative","FEATURE",true,2118,[0],[1],[0.0325779037],[69],[0.0315165839],[0.1775291071],0.0302545496,false,false,"relationship"],[0,0,0,"Own-child","FEATURE",true,10095,[0],[1],[0.0140663695],[142],[0.0138685067],[0.1177646243],0.1442019255,false,false,"relationship"],[0,0,0,"Unmarried","FEATURE",true,7250,[0],[1],[0.0591724138],[429],[0.0556710392],[0.2359471111],0.1035625518,false,false,"relationship"],[0,0,0,"Wife","FEATURE",true,3236,[0],[1],[0.4598269468],[1488],[0.2483861258],[0.4983835128],0.0462246093,false,false,"relationship"],[0,0,0,"__MASK__","FEATURE",true,4578,[0],[1],[0.1878549585],[860],[0.1525654731],[0.3906389716],0.0653943948,true,false,"relationship"],[0,0,0,"?","FEATURE",true,4145,[0],[1],[0.0911942099],[378],[0.082877826],[0.2878850916],0.0592092106,false,false,"workclass"],[0,0,0,"Federal-gov","FEATURE",true,1969,[0],[1],[0.376333164],[741],[0.2347065137],[0.4844651831],0.0281261606,false,false,"workclass"],[0,0,0,"Local-gov","FEATURE",true,4443,[0],[1],[0.2959711906],[1315],[0.2083722449],[0.4564780881],0.0634659886,false,false,"workclass"],[0,0,0,"Never-worked","FEATURE",true,16,[0],[0],[0],[0],[0],[0],0.0002285518,false,false,"workclass"],[0,0,0,"Private","FEATURE",true,47468,[0],[1],[0.2063916744],[9797],[0.1637941511],[0.4047149011],0.6780561666,false,false,"workclass"],[0,0,0,"Self-emp-inc","FEATURE",true,2223,[0],[1],[0.5537561853],[1231],[0.2471102725],[0.4971018734],0.031754421,false,false,"workclass"],[0,0,0,"Self-emp-not-inc","FEATURE",true,5225,[0],[1],[0.2750239234],[1437],[0.199385765],[0.4465263318],0.0746364597,false,false,"workclass"],[0,0,0,"State-gov","FEATURE",true,2792,[0],[1],[0.2596704871],[725],[0.1922417252],[0.4384537892],0.0398822958,false,false,"workclass"],[0,0,0,"Without-pay","FEATURE",true,33,[0],[1],[0.0606060606],[2],[0.056932966],[0.2386062992],0.0004713882,false,false,"workclass"],[0,0,0,"__MASK__","FEATURE",true,1692,[0],[1],[0.2742316785],[464],[0.199028665],[0.4462581807],0.0241693569,true,false,"workclass"]],"foreign_keys": [],"labels": [],"types": [{"data_type": "ANY"},{"data_type": "ANY"},{"data_type": "ANY"},{"data_type": "STRING","format": null},{"data_type": "STRING","format": null},{"data_type": "BOOLEAN"},{"data_type": "NUMBER","format": "INT64"},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "NUMBER","format": "FLOAT64"},{"data_type": "BOOLEAN"},{"data_type": "BOOLEAN"},{"data_type": "STRING","format": null}]},"views_version": {"major_version": 0,"minor_version": 5,"patch_version": 0,"build_version": "dev76"}}]}
The request needs view_type set to HISTOGRAM.
Filter by field
Use fields when you only need histogram rows for specific dataset fields.
{"data": [{"view_type": "HISTOGRAM","output_version": {"major_version": 1,"minor_version": 1,"patch_version": 1},"view_data": {"columns": ["bin_index","bin_low","bin_high","token","field_type","is_categorical","frequency","target_min","target_max","target_mean","target_sum","target_var","target_stddev","frequency_fraction","is_masked_token","is_infrequent","field"],"index": [17,18,19],"data": [[0,0,0,"Female","FEATURE",true,22198,[0],[1],[0.1159113434],[2573],[0.1024759038],[0.3201185778],0.3170871068,false,false,"gender"],[0,0,0,"Male","FEATURE",true,41938,[0],[1],[0.2931708713],[12295],[0.2072217115],[0.4552161152],0.5990629375,false,false,"gender"],[0,0,0,"__MASK__","FEATURE",true,5870,[0],[1],[0.2081771721],[1222],[0.1648394371],[0.4060388203],0.0838499557,true,false,"gender"]],"foreign_keys": [],"labels": [],"types": [{"data_type": "ANY"},{"data_type": "ANY"},{"data_type": "ANY"},{"data_type": "STRING","format": null},{"data_type": "STRING","format": null},{"data_type": "BOOLEAN"},{"data_type": "NUMBER","format": "INT64"},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "INT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "ARRAY","format": {"data_type": "NUMBER","format": "FLOAT64"}},{"data_type": "NUMBER","format": "FLOAT64"},{"data_type": "BOOLEAN"},{"data_type": "BOOLEAN"},{"data_type": "STRING","format": null}]},"views_version": {"major_version": 0,"minor_version": 5,"patch_version": 0,"build_version": "dev76"}}]}
This is useful when the dataset has many fields and you only need to inspect a small subset.
Output
The response follows the shared Response structure format.
The Dataset histogram view returns a single dataframe in view_data.
| Dataframe | Description |
|---|---|
view_data | Histogram rows for dataset fields, including bin information, frequency values, target statistics, and field metadata. |
Interpret the result
The Dataset histogram view is easiest to read by selecting a field first, then comparing the bins or categories for that field.
Start with the field
Use field to identify the dataset field represented by each row.
Use field_type to distinguish features from targets. Feature rows describe input distributions. Target rows describe target distributions.
Separate categorical and numeric fields
Use is_categorical to understand how to read the row.
For categorical fields, token identifies the category. For numeric fields, bin_index, bin_low, and bin_high describe the numeric bin.
Review frequency
Use frequency to see the number of rows in the category or bin.
Use frequency_fraction to compare categories or bins on a normalized scale. This is usually the easiest way to spot imbalance across a field.
Check infrequent or masked values
Use is_infrequent to identify rare categories.
Use is_masked_token to identify masked tokens. These rows are useful when reviewing whether sensitive, missing, rare, or protected values are being represented as expected.
Inspect target statistics
Use the target_* fields to understand how target values behave within each category or bin.
For example, target_mean can show whether a category or numeric range is associated with higher or lower target values. target_min, target_max, target_sum, target_var, and target_stddev provide additional context.
target_var and target_stddev use population formulas with denominator n (ddof=0). For a category or bin with one non-null target value, both values are 0.
Options
The Dataset histogram view supports one view-specific option.
| Option | Use |
|---|---|
fields | Restrict the histogram output to one or more dataset fields. |
Fields
Use fields to request histogram rows for specific fields.
If fields is omitted, the view returns histogram rows for the default set of available dataset fields.
Field reference
The Dataset histogram view returns a dataframe, so individual columns are not documented as standalone API schema properties.
view_data
The view_data dataframe contains the histogram output.
| Field | Description |
|---|---|
bin_index | Index of the numeric bin, when the row represents a numeric bin. |
bin_low | Lower bound of the numeric bin, when available. |
bin_high | Upper bound of the numeric bin, when available. |
token | Category token, when the row represents a categorical value. |
field_type | Type of field represented by the row, such as FEATURE or TARGET. |
is_categorical | Whether the field is categorical. |
frequency | Number of dataset rows in the category or bin. |
target_min | Minimum target value for rows in the category or bin. |
target_max | Maximum target value for rows in the category or bin. |
target_mean | Mean target value for rows in the category or bin. |
target_sum | Sum of target values for rows in the category or bin. |
target_var | Population variance of target values for rows in the category or bin, using denominator n. |
target_stddev | Population standard deviation of target values for rows in the category or bin, using denominator n. |
frequency_fraction | Fraction of dataset rows represented by the category or bin. |
is_masked_token | Whether the row represents a masked token. |
is_infrequent | Whether the row represents an infrequent category or value. |
field | Dataset field represented by the row. |

