implemented some of Randy's suggestions with FRAME number