C Library Functions  - discr3 (3)

NAME

discr3(3f) - [M_datapac:STATISTICS] bin the elements of a vector (output vector contains 1’s, 2’s, 3’s, and so on)

CONTENTS

Synopsis
Description
Options
Examples
Author
Maintainer
License

SYNOPSIS

SUBROUTINE DISCR3(X,N,Numcla,Y)

DESCRIPTION

discr3(3f) ’discretizes’ the data on the REAL vector x into numcla classes.

all values in the vector x within a given class will be mapped into the class number (1, 2, ... , numcla). thus all the elements in the lowermost class will be mapped into the value 1.0; all the elements of x in the next higher class will be mapped into 2.0; etc.

the sample minimum and sample maximum are automatically computed internally and the class width (xdel) is computed as the (sample max
o sample min)/numcla. the first class interval is from the sample min to the sample min + xdel; the second class interval is from the sample min + xdel to the sample min + 2*xdel; ...;
the last class interval is from the sample max - xdel to the sample max. the use of discr3(3f) (and the discre and discr2 subroutines) gives the data analyst the capability of constructing a discrete variate from a continuous one.

the resulting discrete variate might then (for example) be analyzed in itself for gross structure, or for adherence to some theoretical discrete probability model, or the discrete variate might be used as a subset definition vector for some other variate.

this discr3 subroutine is particularly suited to this last purpose inasmuch as it output’s 1’s, 2’s, etc. rather than midpoints.

OPTIONS

X description of parameter
Y description of parameter

EXAMPLES

Sample program:

   program demo_discr3
   use M_datapac, only : discr3
   implicit none
   ! call discr3(x,y)
   end program demo_discr3

Results:

AUTHOR

The original DATAPAC library was written by James Filliben of the Statistical Engineering Division, National Institute of Standards and Technology.

MAINTAINER

John Urban, 2022.05.31

LICENSE

CC0-1.0


Nemo Release 3.1 discr3 (3) July 22, 2023
Generated by manServer 1.08 from a7b9d42a-c565-4584-9deb-65606db9100d using man macros.