line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Text::NumericData::App::txdstatistics; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
921
|
use Text::NumericData::Stat; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
32
|
|
4
|
1
|
|
|
1
|
|
6
|
use Text::NumericData::App; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
197
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
# This is just a placeholder because of a past build system bug. |
7
|
|
|
|
|
|
|
# The one and only version for Text::NumericData is kept in |
8
|
|
|
|
|
|
|
# the Text::NumericData module itself. |
9
|
|
|
|
|
|
|
our $VERSION = '1'; |
10
|
|
|
|
|
|
|
$VERSION = eval $VERSION; |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
#the infostring says it all |
13
|
|
|
|
|
|
|
my $infostring = "do basic statistics on textual data files |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
$0 < data.dat |
16
|
|
|
|
|
|
|
would yield in some statistics about the columns in the file being printed. |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
This is designed as an enhancement over txdmean, giving info like standard error in a more extensible format (to later add more measures)."; |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
our @ISA = ('Text::NumericData::App'); |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub new |
23
|
|
|
|
|
|
|
{ |
24
|
1
|
|
|
1
|
0
|
120
|
my $class = shift; |
25
|
|
|
|
|
|
|
|
26
|
1
|
|
|
|
|
29
|
return $class->SUPER::new |
27
|
|
|
|
|
|
|
({ |
28
|
|
|
|
|
|
|
parconf=> |
29
|
|
|
|
|
|
|
{ |
30
|
|
|
|
|
|
|
info=>$infostring # default version |
31
|
|
|
|
|
|
|
# default author |
32
|
|
|
|
|
|
|
# default copyright |
33
|
|
|
|
|
|
|
}, |
34
|
|
|
|
|
|
|
filemode=>1 |
35
|
|
|
|
|
|
|
,pipemode=>1 |
36
|
|
|
|
|
|
|
,pipe_file=>\&process_file |
37
|
|
|
|
|
|
|
}); |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
sub process_file |
41
|
|
|
|
|
|
|
{ |
42
|
1
|
|
|
1
|
0
|
2
|
my $self = shift; |
43
|
1
|
|
|
|
|
4
|
my $out = Text::NumericData::Stat::generate($self->{txd}); |
44
|
1
|
|
|
|
|
8
|
$out->write_all($self->{out}); |
45
|
|
|
|
|
|
|
} |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
1; |