| 561 | } |
| 562 | |
| 563 | static int usage (struct GMTAPI_CTRL *API, int level) { |
| 564 | const char *name = gmt_show_name_and_purpose (API, THIS_MODULE_LIB, THIS_MODULE_CLASSIC_NAME, THIS_MODULE_PURPOSE); |
| 565 | if (level == GMT_MODULE_PURPOSE) return (GMT_NOERROR); |
| 566 | GMT_Usage (API, 0, "usage: %s [<table>] %s -T[<min>/<max>/]<inc>[+i|n] [-A] [%s] [-C<cpt>[+b]] [-D[+b][+f<font>][+o<off>][+r]] " |
| 567 | "[-E<width>[+o<offset>]] [-F] [-G<fill>] [-I[o|O]] %s[-Ll|h|b] [-N[<mode>][+p<pen>]] %s%s[-Q[r]] [%s] [-S] [%s] [%s] " |
| 568 | "[-W<pen>] [%s] [%s] [-Z[<mode>][+w]] %s[%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s]\n", |
| 569 | name, GMT_Jx_OPT, GMT_B_OPT, API->K_OPT, API->O_OPT, API->P_OPT, GMT_Rx_OPT, GMT_U_OPT, GMT_V_OPT, GMT_X_OPT, GMT_Y_OPT, |
| 570 | API->c_OPT, GMT_bi_OPT, GMT_di_OPT, GMT_e_OPT, GMT_f_OPT, GMT_h_OPT, GMT_i_OPT, GMT_o_OPT, GMT_p_OPT, GMT_qi_OPT, GMT_s_OPT, |
| 571 | GMT_t_OPT, GMT_w_OPT, GMT_PAR_OPT); |
| 572 | |
| 573 | if (level == GMT_SYNOPSIS) return (GMT_MODULE_SYNOPSIS); |
| 574 | |
| 575 | GMT_Message (API, GMT_TIME_NONE, " REQUIRED ARGUMENTS:\n"); |
| 576 | GMT_Option (API, "<"); |
| 577 | GMT_Usage (API, 1, "\n-Jx|X<x-scl>|<width>[/<y-scl>|<height>] for Cartesian scaling."); |
| 578 | GMT_Usage (API, 1, "\n-T[<min>/<max>/]<inc>[+i|n]"); |
| 579 | GMT_Usage (API, -2, "Make evenly spaced bin boundaries from <min> to <max> by <inc>. " |
| 580 | "If <min>/<max> is not given then boundaries in -R is used. " |
| 581 | "For absolute time bins, append a valid time unit (%s) to the increment.", GMT_TIME_UNITS_DISPLAY); |
| 582 | GMT_Usage (API, 3, "+n Indicate <inc> is the number of bin boundaries to produce instead."); |
| 583 | GMT_Usage (API, 3, "+i Indicate <inc> is the reciprocal of desired <inc> (e.g., 3 for 0.3333.....)."); |
| 584 | GMT_Usage (API, -2, "Alternatively, give a file with bin boundaries in the first column, or a comma-separate list of values."); |
| 585 | GMT_Message (API, GMT_TIME_NONE, "\n OPTIONAL ARGUMENTS:\n"); |
| 586 | GMT_Usage (API, 1, "\n-A Plot horizontal bars, i.e., flip x and y axis [Default is vertical]."); |
| 587 | GMT_Option (API, "B-"); |
| 588 | GMT_Usage (API, 1, "\n-C<cpt>[+b]"); |
| 589 | GMT_Usage (API, -2, "Use CPT to assign color to bars based on the mid-bar coordinate. Alternatively, append +b " |
| 590 | "to assign color based on the histogram value instead (count or percent only; see -Z)."); |
| 591 | GMT_Usage (API, 1, "\n-D[+b][+f<font>][+o<off>][+r]"); |
| 592 | GMT_Usage (API, -2, "Place histogram count labels on top of each bar; optionally append modifiers:"); |
| 593 | GMT_Usage (API, 3, "+b Place the labels beneath the bars [above]."); |
| 594 | GMT_Usage (API, 3, "+f Sets the label <font> [FONT_ANNOT_PRIMARY]."); |
| 595 | GMT_Usage (API, 3, "+o Sets the offset <off> between bar and label [6p]."); |
| 596 | GMT_Usage (API, 3, "+r Rotate the label to be vertical [horizontal]."); |
| 597 | GMT_Usage (API, 1, "\n-E<width>[+o<offset>]"); |
| 598 | GMT_Usage (API, -2, "Use custom bar <width> and optionally <offset>. " |
| 599 | "By default, the bar width is implicitly set via -T and the offset is zero. " |
| 600 | "Append desired bar width in data units, or append a valid unit (%s) for a fixed width.", GMT_DIM_UNITS_DISPLAY); |
| 601 | GMT_Usage (API, 3, "+o Add an offset in data units, or append a valid unit (%s) for a fixed offset [0].", GMT_DIM_UNITS_DISPLAY); |
| 602 | GMT_Usage (API, 1, "\n-F The bin boundaries given should be considered bin centers instead."); |
| 603 | gmt_fill_syntax (API->GMT, 'G', NULL, "Select color/pattern for columns."); |
| 604 | GMT_Usage (API, 1, "\n-I[o|O]"); |
| 605 | GMT_Usage (API, -2, "Inquire about min/max x and y. No plotting is done. Optionally append a directive:"); |
| 606 | GMT_Usage (API, 3, "o: Output the resulting x, y data."); |
| 607 | GMT_Usage (API, 3, "O: Output all resulting x, y data even with y=0."); |
| 608 | GMT_Option (API, "K"); |
| 609 | GMT_Usage (API, 1, "\n-Ll|h|b"); |
| 610 | GMT_Usage (API, -2, "Append l|h|b to place extreme values in the first, last, or both bins [skip extremes]."); |
| 611 | GMT_Usage (API, 1, "\n-N[<mode>][+p<pen>]"); |
| 612 | GMT_Usage (API, -2, "Draw the equivalent normal distribution; append desired pen [0.25p,black]. " |
| 613 | "The <mode> selects which central location and scale to use:"); |
| 614 | GMT_Usage (API, 3, "0: Mean and standard deviation [Default]."); |
| 615 | GMT_Usage (API, 3, "1: Median and L1 scale (MAD w.r.t. median)."); |
| 616 | GMT_Usage (API, 3, "2: LMS mode and LMS scale (MAD w.r.t. mode)."); |
| 617 | GMT_Usage (API, -2, "Note: The -N option may be repeated to draw several of these curves."); |
| 618 | GMT_Option (API, "O,P"); |
| 619 | GMT_Usage (API, 1, "\n-Q[r]"); |
| 620 | GMT_Usage (API, -2, "Plot a cumulative histogram; append r for reverse cumulative histogram. " |
no test coverage detected