Date: Wed, 17 Nov 1999 09:17:49 -0800
Reply-To: Stephen Arthur <sarthur67@YAHOO.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Stephen Arthur <sarthur67@YAHOO.COM>
Subject: Stepping through a sequence of data until a criteria is met
Content-Type: text/plain; charset=us-ascii
Hi,
I have an ordered list of 73 (this is really
arbitrary) items with values of 'A', 'T', 'C', 'G'.
I want to obtain a continuous sequence of these
letters that is 50 'bases' long. The only criteria
being that the 'C' and 'G' letters make up at least
50% of an accepted sequence. If starting from
position one the sequence fails the 50% criteria test,
I want to be able to read the next 50 bases from
position 2, etc...
T G A G A T C A C T T C C C T T G C
A C A G T T T G G A A G G G A G A G
C A C T T T A T T A C A G A C C T T
G G A A G C A A G A G G A T T G
C A T
I have already taken the meager step (below) to read
in the sequence, and I am currently trying to work out
an algorithm to complete this task.
Any help would be welcomed,
steve
data dna73;
retain i 0;
infile cards;
input base $ @@;
i + 1;
if 1 le i le 73 then output dna73;
cards;
T G A G A T C A C T T C C C T T G C
A C A G T T T G G A A G G G A G A G
C A C T T T A T T A C A G A C C T T
G G A A G C A A G A G G A T T G
C A T
;
__________________________________________________
Do You Yahoo!?
Bid and sell for free at http://auctions.yahoo.com