Yes you can! It'll just take a little longer to get max raider rep. My suggestion is for you to determine which vendor items you want to focus on (i.e. gauss shotgun with the settlers, gauss minigun with the raiders, etc) and side with that faction so you get maximum rep. For instance, I run a heavy build, so it was more important for me to side with the raiders to get their max rep faster.