I was wondering can anyone give me a clue how to start script which would do the following:
I have 2 numbers as input for example: 100 and 1000 and I need to create file and in that file should be written
100 - 199
200 - 299
300 - 399
400 - 499
500 - 599
600 - 699
700 - 799... (3 Replies)
#!/usr/bin/perl -w
use strict;
open(FH,"$ARGV") or die;
my @temp=<FH>;
close FH;
my $mean = Mean(\@temp);
my $var = variance(\@temp);
print "$var\n";
sub estimate_variance {
my ($arrayref) = @_;
my ($mean,$result) = (mean($arrayref),0);
foreach (@$arrayref) {... (4 Replies)
Hi,
How do I calculate time? I need to create an alert if a process is running more than 30 minutes.
I need to get the first time and then get another, calculate it if more than 30 mins and then alert it to pager.
Can't find it in internet.
Thanks in advance,
itik (2 Replies)
I have 2 variables in my shell scripts in which i am using awk and calculating 2 files and getting 2 different variable called in_total and out_total. I want to subtract one variable from another so plz tell me how i can do that.
Example is:
cat in_file | awk -F: '{
in_total += $1 * 86400... (3 Replies)
Hello,
I'm trying to create a shell script (#!/bin/sh) which should tell me the age of a file in minutes...
I have a process, which delivers me all 15 minutes a new file and I want to have a monitoring script, which sends me an email, if the present file is older than 20 minutes.
To do... (10 Replies)
Hi all,
I am attempting to calculate a running variance for a file containing a column of numbers. I am using the formula variance=sum((x-mean(x))^2)/(n-1), where x is the value on the current row, and mean(x) is the average of all of the values up until that row. n represents the total number... (1 Reply)
I would like to calculate
1/n
In awk, I wrote the following line for the sigma summation:
{ summ+=($1-average)^2 }
Full code:
BEGIN { Print "This script calculate error estimates"; sum=0 }
{ sum+=$1; n++ }
END { average = sum/n }
BEGIN { summ=0 }
{ summ+=($1-average)^2 }
END { print... (8 Replies)
i have file input
abcedef|wert|13|03|10|04|23|A1|13|05|01|09|31
fsdasdf|ferg|12|04|25|21|21|A1|13|02|26|20|31
dfsfsad|gerg|12|04|25|21|21|A1|13|02|25|25|31
i expect the output
abcedef|wert|13|03|10|04|23|A1|13|05|01|09|31|9.516666667... (5 Replies)
11☺Hi,
I have to data sets:
One is in .txt format and other is in .csv format, please refer below two outputs from two files.
File1.txt
SOURCE PAYDATE TOTAL_DOLLARS RECORD_COUNT
ASSET 05/25/2018 247643.94
ASSET 06/20/2018 ... (27 Replies)
Discussion started by: Tahir_M
27 Replies
LEARN ABOUT DEBIAN
transforms
transforms(3U) InterViews Reference Manual transforms(3U)NAME
MoveCmd, RotateCmd, ScaleCmd - coordinate transformation commands
SYNOPSIS
#include <Unidraw/Commands/transforms.h>
DESCRIPTION
The Unidraw library predefines three purely interpretive commands for performing coordinate transformations: MoveCmd defines a translation,
RotateCmd defines a rotation, and ScaleCmd defines a two-dimensional scaling.
MOVECMD PUBLIC OPERATIONS
MoveCmd(ControlInfo*, float dx = 0, float dy = 0)
MoveCmd(Editor* = nil, float = 0, float = 0)
Construct a new MoveCmd, specifying the translation distances in the horizontal (dx) and vertical (dy) dimensions.
void GetMovement(float&, float&)
Return the translation distances specified in the constructor.
ROTATECMD PUBLIC OPERATIONS
RotateCmd(ControlInfo*, float = 0)
RotateCmd(Editor* = nil, float = 0)
Construct a new RotateCmd, specifying the rotation angle in degrees.
float GetRotation()
Return the rotation angle specified in the constructor.
SCALECMD PUBLIC OPERATIONS
ScaleCmd(
ControlInfo*, float sx = 1, float sy = 1, Alignment = Center
)
ScaleCmd(Editor* = nil, float = 1, float = 1, Alignment = Center)
Construct a new ScaleCmd, specifying the scaling factors in the horizontal (sx) and vertical (sy) dimensions and an alignment sug-
gesting the point about which the component should be scaled.
void GetScaleing(float&, float&)
Alignment GetAlignment()
Return the scaling factors and alignment specified in the constructor.
SEE ALSO Command(3U)Unidraw 24 January 1991 transforms(3U)