Sponsored Content
Top Forums Programming To Perl or not to Perl, that is the question... ;o) Post 303037700 by stomp on Friday 9th of August 2019 05:40:11 PM
Old 08-09-2019
I'm not a great perl hacker either. It was my first Scripting Language after bash in Linux ~20 years ago. The syntax is uncomfortable to me. It's quite fast. It's a usable general purpose scripting language, that scales a lot beyond shell scripting. I hadn't been using it for real work for a long time now.

I would not say it is a must learn. It has some unique points in it's purpose of using. So I will probably use it, if those points matter.

- great stability of syntax (stick to version ~5.00x if you like to have that)
- great availability(still available in the newest systems)

Some people still use it for current code(e. g. Proxmox, great open source virtualization management solution and mail filtering solution).

If you like to generate good code, you may do in perl too(or even the opposite - if you like).

The version number rised considerably in the last years and wikipedia mentions that features of the not-really-used perl 6 are being integrated zu perl 5 step by step. Maybe those features are worth a look?

Perl 5 version history - Wikipedia

Its Anti-Hype atmosphere appears kind of cool to me.

Last edited by stomp; 08-09-2019 at 07:26 PM..
This User Gave Thanks to stomp For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

PERL Question

Can anyone tell me if the copy command in PERL has the same functionality as in KSH shell in UNIX or does it actually move the file ?? $cp_stat=system("cp $ENV{OLAMEBSDIR}/data/olam.ddabal$type $ENV{OLAMDIR}/balance/data/olam.ddabal$type.$HeaderDate"); (1 Reply)
Discussion started by: frank
1 Replies

2. Shell Programming and Scripting

PERL question

Could someone tell me what is wrong with these PERL statements it is always setting the $status2 to the number inside of the brackets......why???????? if (/^Status:/) { $stat = $Fld; print "\$stat is $stat\n"; } the above is where i'm searching for a string... (1 Reply)
Discussion started by: frank
1 Replies

3. Shell Programming and Scripting

Question about Perl

Where can i find solid information about programming in Perl? Thank you in advance!!!:) (5 Replies)
Discussion started by: SolidSnake
5 Replies

4. Shell Programming and Scripting

Perl: tk question

When i run my perl/tk script, a perl window pops up behind the GUI window,, can this be hidden???? Also, can the Icon be changed, the Tk icon in every window??? (1 Reply)
Discussion started by: perleo
1 Replies

5. Shell Programming and Scripting

perl question

If I use 2 system commands in a script, will one finish before the next one starts? or will it start the first and the second at the same time? i.e. system("ps | grep rminer"); system("ls -al | grep 431"); (1 Reply)
Discussion started by: BG_JrAdmin
1 Replies

6. Shell Programming and Scripting

Perl Question

Hi everyone I am not even a novice at Perl scripting .. but had to edit one the other day. The only way I can get it to run is by prefixing 'perl' before running it - ie # perl scriptname I am running AIX. Any ideas why i have to do that ? Thanks! (2 Replies)
Discussion started by: serm
2 Replies

7. Shell Programming and Scripting

PERL I/O question

Playing with an until loop as follows: my $input; until ($input eq "quit") { print "Please enter something:"; $input = <STDIN>; chomp $input; if ($input eq "dog") { print "cat" ; } else { print "Please re-enter"; } } Something simple like this... I want to prompt the user to... (3 Replies)
Discussion started by: yesokay
3 Replies

8. Shell Programming and Scripting

Perl question!

Hi All, I am new to perl and just want to read the text file and write back it into another file with some modification. Here is my requirement: input file: USB_OTG_PATH top.usb_top.otg_top USB_HSIC_PATH top.usb_top.hsic_top .. (All starts with USB_) ... START_PATH USB_OTG_PATH.interrupt... (2 Replies)
Discussion started by: surisingh
2 Replies

9. Shell Programming and Scripting

Perl question

Hi All, I am new to Perl and got a real stupid question. We are trying to install the Date:Calc package for some calculations with dates.The security guys mentioned they won't install it as root in /usr/bin/perl but have asked us to install it in any directory and use it from there. Here's the... (2 Replies)
Discussion started by: nua7
2 Replies

10. Programming

PERL: In a perl-scripttTrying to execute another perl-script that SETS SOME VARIABLES !

I have reviewed many examples on-line about running another process (either PERL or shell command or a program), but do not find any usefull for my needs way. (Reviewed and not useful the system(), 'back ticks', exec() and open()) I would like to run another PERL-script from first one, not... (1 Reply)
Discussion started by: alex_5161
1 Replies
FITCIRCLE(l)															      FITCIRCLE(l)

NAME
fitcircle - find mean position and pole of best-fit great [or small] circle to points on a sphere. SYNOPSIS
fitcircle [ xyfile ] -Lnorm [ -H[nrec] ] [ -S ] [ -V ] [ -: ] [ -bi[s][n] ] DESCRIPTION
fitcircle reads lon,lat [or lat,lon] values from the first two columns on standard input [or xyfile]. These are converted to cartesian three-vectors on the unit sphere. Then two locations are found: the mean of the input positions, and the pole to the great circle which best fits the input positions. The user may choose one or both of two possible solutions to this problem. The first is called -L1 and the second is called -L2. When the data are closely grouped along a great circle both solutions are similar. If the data have large dispersion, the pole to the great circle will be less well determined than the mean. Compare both solutions as a qualitative check. The -L1 solution is so called because it approximates the minimization of the sum of absolute values of cosines of angular distances. This solution finds the mean position as the Fisher average of the data, and the pole position as the Fisher average of the cross-products between the mean and the data. Averaging cross-products gives weight to points in proportion to their distance from the mean, analogous to the "leverage" of distant points in linear regression in the plane. The -L2 solution is so called because it approximates the minimization of the sum of squares of cosines of angular distances. It creates a 3 by 3 matrix of sums of squares of components of the data vectors. The eigenvectors of this matrix give the mean and pole locations. This method may be more subject to roundoff errors when there are thousands of data. The pole is given by the eigenvector corresponding to the smallest eigenvalue; it is the least-well represented factor in the data and is not easily estimated by either method. -L Specify the desired norm as 1 or 2, or use -L or -L3 to see both solutions. OPTIONS
xyfile ASCII [or binary, see -b] file containing lon,lat [lat,lon] values in the first 2 columns. If no file is specified, fitcircle will read from standard input. -H Input file(s) has Header record(s). Number of header records can be changed by editing your .gmtdefaults file. If used, GMT default is 1 header record. -S Attempt to fit a small circle instead of a great circle. The pole will be constrained to lie on the great circle connecting the pole of the best-fit great circle and the mean location of the data. -V Selects verbose mode, which will send progress reports to stderr [Default runs "silently"]. -: Toggles between (longitude,latitude) and (latitude,longitude) input/output. [Default is (longitude,latitude)]. Applies to geo- graphic coordinates only. -bi Selects binary input. Append s for single precision [Default is double]. Append n for the number of columns in the binary file(s). [Default is 2 input columns]. EXAMPLES
Suppose you have lon,lat,grav data along a twisty ship track in the file ship.xyg. You want to project this data onto a great circle and resample it in distance, in order to filter it or check its spectrum. Try: fitcircle ship.xyg -L2 project ship.xyg -Cox/oy -Tpx/py -S -pz | sample1d -S-100 -I1 > output.pg Here, ox/oy is the lon/lat of the mean from fitcircle, and px/py is the lon/lat of the pole. The file output.pg has distance, gravity data sampled every 1 km along the great circle which best fits ship.xyg SEE ALSO
gmt(1gmt), project(1gmt), sample1d(1gmt) 1 Jan 2004 FITCIRCLE(l)
All times are GMT -4. The time now is 12:01 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy