it depends on where you're calling it from. it could be
actor.name
@actor.name
actors[0].name
etc...
If you're calling it from an event, it would be
$game_actors[n].name # n is the database actor id
or
$game_party.actors[n].name # n is the position in the party starting with 0