“直方图”的版本间差异
跳到导航
跳到搜索
无编辑摘要 |
无编辑摘要 |
||
第5行: | 第5行: | ||
sdssidl中的plothist由于和[[astro_lib]]中的plothist重名,被改为sdssidl_plothist |
sdssidl中的plothist由于和[[astro_lib]]中的plothist重名,被改为sdssidl_plothist |
||
== HISTOGRAM == |
== HISTOGRAM == |
||
Result = HISTOGRAM( Array [, BINSIZE=value] [, INPUT=variable] [, LOCATIONS=variable] [, MAX=value] [, MIN=value] [, /NAN] |
Result = HISTOGRAM( Array [, BINSIZE=value] [, INPUT=variable] [, LOCATIONS=variable] [, MAX=value] [, MIN=value] [, /NAN] |
||
[, NBINS=value] [, OMAX=variable] [, OMIN=variable] [, /L64 | REVERSE_INDICES=variable] ) |
[, NBINS=value] [, OMAX=variable] [, OMIN=variable] [, /L64 | REVERSE_INDICES=variable] ) |
||
*关键词 locations是bin的位置 = MIN + v*BINSIZE, with v = 0,1,...,NBINS-1. |
*关键词 locations是bin的位置 = MIN + v*BINSIZE, with v = 0,1,...,NBINS-1. |
||
*BINSIZE = (MAX – MIN) / (NBINS – 1) |
*BINSIZE = (MAX – MIN) / (NBINS – 1) |
||
第19行: | 第16行: | ||
/AUTOBIN, ...plotting keywords] |
/AUTOBIN, ...plotting keywords] |
||
*不能设置min,max等关键词 |
*不能设置min,max等关键词 |
||
== cghistoplot == |
== cghistoplot == |
||
cgHistoplot, Fix(RandomU(seed, 200)*20), POLYCOLOR=['charcoal', 'steel blue'], /FILLPOLYGON |
cgHistoplot, Fix(RandomU(seed, 200)*20), POLYCOLOR=['charcoal', 'steel blue'], /FILLPOLYGON |
||
2012年4月25日 (三) 15:07的版本
IDL自带的HISTOGRAM可以运算直方图,然后用plot命令画出来
- PSYM=10可画成直方图形式,但是缺少直方图的边框
astro_lib中的plothist;Coyote库中的cgplothist;
sdssidl中的plothist由于和astro_lib中的plothist重名,被改为sdssidl_plothist
HISTOGRAM
Result = HISTOGRAM( Array [, BINSIZE=value] [, INPUT=variable] [, LOCATIONS=variable] [, MAX=value] [, MIN=value] [, /NAN] [, NBINS=value] [, OMAX=variable] [, OMIN=variable] [, /L64 | REVERSE_INDICES=variable] )
- 关键词 locations是bin的位置 = MIN + v*BINSIZE, with v = 0,1,...,NBINS-1.
- BINSIZE = (MAX – MIN) / (NBINS – 1)
plothist
plothist, arr, xhist, yhist, [, BIN=, /FILL, /NOPLOT, /OVERPLOT, PEAK=, /AUTOBIN, ...plotting keywords]
- 不能设置min,max等关键词
cghistoplot
cgHistoplot, Fix(RandomU(seed, 200)*20), POLYCOLOR=['charcoal', 'steel blue'], /FILLPOLYGON
- 可以用mininput,maxinput设置MIN,MAX;
- locations,histdata关键词可给出Xbin和Yhist的数值
- 颜色的处理很强大
- 似乎没有直接画面积归一化的直方图功能
sdssidl_plothist
plothist, array, weights=, peak=, norm=, aspect=, /error, nboot=, /noplot, /overplot, /fill, fcolor=, /fline, forientation=, fpattern=, fspacing= xhist=, yhist=, reverse_indices= ...plotting keywords...histogram keywords]
- 直接支持plotting,histogram keywords的关键词,很强大,比如overplot功能
- norm,peak,weights的功能很贴心