Folks,
This may be a naive query, but dashed if I know it.
I have a large dataset, of financial data, and I need to check the
results of some trading strategies on it. I have read the data into a
hash of hashes of hashes, as I believe it's better than read this into
an array (Or
Is this a snaFu? :)
best,
-tir
On Wed, Dec 04, 2002 at 02:07:18AM -0800, Timothy Johnson gushed in an explosion of
ASCII chars:
>
> My thoughts exactly.
>
> -Original Message-
> From: Daniel Falkenberg [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 03, 2002 11:06 PM
> To: [EMAI
> On Saturday, June 29, 2002, at 11:16 , Ronnie Livingston wrote:
>
> > I have a question though, will someone still be able to post to the list
> > if they are no longer subscribed to them??
>
> An Interesting problem -
>
> What I do is have my mail filter my lists into the requisite folder
hi Ron,
another unix command is flip.
i've written a small perl script that converts a dos file to a unix
one.
as you can see, i've just substituted the \r\n with a \n. the reverse
can easily be done. this is a working example. it's not fast, but
workable. i'd welcome a
t.file") || die "Can't open for write: $!";
> open(COMMAND, "bunzip2 -c $ParseFile | discretise $delta $BOD $EOD |") or
> die "Cann't execute: $!";
> while(){
> print OUTPUT;
> }
> close COMMAND;
> close OUTFILE;
>
>
\*ZIPIT);
I tried this, and it didn't work. I am confused. Sorry, but please
explain. A working complete example would be great.
TIA,
-tir
>
> perldoc IPC::Open2
>
> > -Original Message-
> > From: Tirthankar C. Patnaik [mailto:[EMAIL PROTECTED]]
>
T pipe and OUTPUT pipe.
>
> Here is how I used it.
>
> open2(*READ, *ZIPIT, "/apps/bin/zip $FORM{'zipfile'} -@ 2>&1");
> READ is the input pipe
> ZIPIT is the output pipe
>
> Perl Gurus, Yeah I should have used the ZIP module.. I am too lazy to chan
Folks,
Consider this code snippet:
Here $ParseFile is a plain-text file, which could be gzipped, bzipped, or
not compressed at all. I'd like my program to determine this, open the
file, and cat it to another program called discretise.
In the code below,
my(@PARSELIST) = @ARGV;
Hi,
perl -e '$r="123456789012345"; @Re=split(//,$r); print join ("|",@Re);'
HTH,
-tir
>
Ol=10 Apr 2002, Daniel Falkenberg wrote:
>t(//,$r); print join ("|",@Re);'
> Hey all,
>
> $card_no = "1234567901234567" # 16 digit number
>
> How would I go about splitting that number into an
nce estimate) = (population
> variance calculation) so that
>
> (20/21)* 38.5 = 36.7
>
> Hope this helps,
> -Nick
>
>
>
>
> "Tirthankar
>
This might seem trivial, but it has me stumped.
The variance of numbers 0..20 is 38.5.
Then why does Math:NumberCruncher show it as 36.6667?
Here's a sample prog, and it's output. Here test04.dat is a file that has
numbers 0 to 20, on separate lines.
#---start
Dear Allison,
> Does anyone know how to write to an Excel document? I've opened the
> document using OLE but I cannot find any documentation on how to store data
> in the spreadsheet. If anyone knows what the commands are to do this please
> let me know. Thanks,
>
Try the SpreadSheet::Pars
You might want to try out the Date::Manip package. It has a function
&Date_Cmp which compares any two dates. You first read the date through the
function &ParseDate in the module, and then compare the dates through
&Date_Cmp.
HTH,
-tir
--
Tirthankar, IGIDR.
+91-22-8400919 x275 (r), x593(
> What does $ stand for in the following statement?
>
> print"$_\t", "*" x $n, "\n";
>
$_ is the default input and pattern-searching space.
Snipped from man perlvar:
PERLVAR(1) Perl Programmers Reference Guide PERLVAR(1)
NAME
perlvar - Perl predefined variables
DESCRIPT
Try
uname -a
On my machine:
uname -a gives,
OSF1 brahma.igidr.ac.in V5.1 1885 alpha
HTH,
-tir
On Tue, 15 Jan 2002, Chris Anderson wrote:
> I need to find out which OS I am on -
> It would be nice to know:
> Ref Hiat
>
This is a test mail, please delete.
-tir
--
Tirthankar, IGIDR.
+91-22-8400919 x275 (r), x593(o), x(542),
+91-22-8421206 (r)
http://www.igidr.ac.in/~tir
Into the mouth of hell
Rode the six hundred.
-Tennyson
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mai
anks,
-tir
On Wed, 5 Dec 2001, Jenda Krynicky wrote:
> From: "Tirthankar C. Patnaik" <[EMAIL PROTECTED]>
> > I have a set of timestamps, which are seconds since midnight.
> >
> > say, 36000
> > 36001
> > 36002
> >
> $ perl -le'use Time::Local;
> my $time = timelocal(0,0,0,5,11,101);
> print scalar localtime($time);
> print scalar localtime($time + 36_000);
> '
> Wed Dec 5 00:00:00 2001
> Wed Dec 5 10:00:00 2001
>
>
Thanks a lot.
-tir
On Wed, 5 Dec 2001,
Could you give a specific code?
Also, apropos to my earlier mail, can this be done using Date::Manip?
-tir
On Wed, 5 Dec 2001, [EMAIL PROTECTED] wrote:
> On Wed, 5 Dec 2001, Tirthankar C. Patnaik wrote:
>
> > Date: Wed, 5 Dec 2001 14:18:35 +0530 (IST)
> > From: Tir
I have a set of timestamps, which are seconds since midnight.
say, 36000
36001
36002
.
I'd like to convert them into the format:
10:00:00
10:00:01
.
Can I do this using Date::Manip, failing, which, is there any other way in
perl?
TIA,
-tir
--
Tirtha
small perl prog I wrote to test this:
#!/usr/bin/perl -w
$_dir = "/tmp/dummy/";
unlink <$_dir/*> if -r $_dir;
exit;
This prog worked on v5.6.1 built for i386-linux.
Best,
-tir
---
> Hello Tirthankar,
>
> Tuesday, Decembe
Are you giving the propoer syntax?
your command should've been:
chmod 0777, $r_file; # added the comma.
HTH,
-tir
On Tue, 4 Dec 2001, Rahul Garg wrote:
> Hi,
>
> I am transfering xyz.txt file from windows98 to linux server manually.
> $r_file = "xyz.txt" ;
> then in perl
You might want to check the permissions of those files.
The command works fine here.
But I guess the mistake is that you're working on Windows, and there you have
a back-slash ( \ ) instead of a slash ( / ).
Try this:
my ($_path) = "c:\EventLogs";
unlink <$_path/*> if -r $_path;
This should
The command is
unlink <$_path/*> if -r $_path;
This will work.
HTH,
-tir
> Hi, I wanted to delete all files under a directory but not the directory
> I tried this:
> my ($_path) = "c:/EventLogs/";
> unlink $_path if -r $_path;
>
> But it didn't delete teh files which are under the direc
24 matches
Mail list logo