Re: Sorting by sequence member`

new topic     » goto parent     » topic index » view thread      » older message » newer message

On 10 Oct 2004, at 18:25, Tony Steward wrote:

> 
> 
> Kat your sorttok doesn't seem to like my data layout (i think) as it
> returns nothing.
> 
> Will it work with data layed out as below?
> 
> {
>                           {
>                             {65'A',67'C',67'C',73'I',68'D',80'P',83'S',65'A',
> 78'N',73'I',71'G',72'H',84'T'},
>                             {65'A',67'C',67'C',73'I',68'D',69'E',78'N',84'T',
> 32' ',38'&',32' ',69'E',77'M',69'E',82'R',71'G',69'E',78'N',67'C',89'Y'},
>                             {80'P',83'S',65'A'},
>                             {78'N',73'I',71'G',72'H',84'T',32' ',80'P',79'O',
> 82'R',84'T',69'E',82'R'},
>                             {},
>                             {},
>                             {},
>                             1
>                           },
>                           {
>                             {65'A',76'L',73'I',83'S',79'O',68'D',65'A',86'V',
> 73'I',83'S',65'A',47'/',78'N',85'U',77'M'},
>                             {65'A',76'L',73'I',83'S',79'O',78'N'},
>                             {68'D',65'A',86'V',73'I',83'S'},
>                             {65'A',47'/',78'N',85'U',77'M',32' ',67'C',65'A',
> 82'R',68'D',73'I',65'A',67'C',32' ',67'C',65'A',84'T',72'H',32' ',76'L',
> 65'A',66'B'},
>                             {},
>                             {},
>                             {},
>                             1
>                           },
>                           {
>                             {65'A',76'L',83'S',79'O',80'P',69'E',83'S',84'T',
> 69'E',76'L',76'L',69'E',83'S',79'O',67'C',73'I',65'A'},
>                             {65'A',76'L',83'S',79'O',80'P'},
>                             {69'E',83'S',84'T',69'E',76'L',76'L',69'E'},
>                             {83'S',79'O',67'C',73'I',65'A',76'L',32' ',87'W',
> 79'O',82'R',75'K'},
>                             {},
>                             {},
>                             {},
>                             0
>                           }
> }
> 
> 
> On Sun, 10 Oct 2004 16:42:13 +1000, Craig Welch
> <euphoria at welchaviation.org> wrote:
> > 
> > 
> > Tony Steward wrote:
> > 
> > > Thanks Kat but where do I find sorttok.
> > 
> > It's part of her strtok, which you can download from
> > http://www.tiggrbox.info/program/Euphoria.html#StrTok

Craig, yeas.
Tony, no. The demos work on nested flat sequences, which you apparently 
do not have. Those 0 and 1 in the example above are atoms. Half your fields 
are empty. I don't know what you sorted them by, where's the code you used 
to attempt it?

What you posted above is NOT what you posted in your first enquiry:

> {{"tony","nsw","Australia"},{"George","qld","Australia"},{"Mary","ca","USA"}}
> ie: how do I sort by state or country

To compare your complaint that sorttok didn't work, this is what you seem to 
have tried:

{{"tony","nsw","Australia","","","",1},{"George","qld","Australia","","","",1},{"Ma
ry","ca","USA","","","",0}}

And i would have said that i hadn't tried sorting atoms before, and no one had 
asked before. But i still don't know what you did.

Kat

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu