What's the problem with this?
if Player:isInGroup(v) and Player:GetRankInGroup(v) == for i,v in pairs(rankid) then
Try this:
for i, v in pairs(rankid) do if Player:IsInGroup(v) and Player:GetRankInGroup(v) > 1 then -- Check the rank in group (1 - 255) if its over 1 continue. -- do stuff end end