So your using:
filter -xwwc @test @test $gettok(atypes,%at,59)
Your not calling atypes as an identifier, so it won't return anything.
It should be:
filter -xwwc @test @test $gettok($atypes,%at,59)
If that is just another case of a typo, sorry, but how am I too know. Try pasting the code you are actually using here.