There's a gym near my house that was held down by blue for several days earlier this week...though I think both the red and blue people who take over that gym are also employees there (the gym is in the middle of an IBM office complex...with 5 pokestops too, I wonder if productivity has gone down over there lol). Blue has more players with 1500-2000+ cp pokemon of several different types. Either way that gym is always up to at least 4 trainer slots.
Sometimes yellow players will take over the gym at night, but only ever at night, as soon as its work hours someone from Red or Blue take it back.
So you only get coins from gyms if your pokemon defeats an attacker? I was under the impression that you got coins based on the amount of time you held the gym down. Or is it both?