I think there is technically enough information in the comments and answers for this to be answered, but as none of the answers has been accepted I'll write it out a bit clearer.
As oals indicated, the "とは” at the end of a sentence (possibly before a ね or な) means "とは思わなかった", which indicates surprise about a state. Note here that は is used after the と because it expresses something negative, which is a common pattern with the は particle.
A similar pattern is ~なんて which can be used to express surprise about something (i.e. こんなに難しいなんて”）
まだ means "still" when used in a positive sentence, and いた comes from 居た (a form of 居る, which generally means a living thing exists or is present). While this seems like the past tense, it is technically the "modal た", which you can read more about here. This usage is seen in other cases, like when you say "あった" when you find something you were looking for.
There are many ways to translate this, and I think that those in ironsand's answer aren't bad. However, assuming the context implies "you", one other way to say this would be:
I'd never have guessed you were still here.
Correction: changed description of "ta" from "past" to "modal" based on feedback from l'électeur.