is it possible for an app to crash the phone at the logo screen stage? My wife has a Samsung Galaxy A5 running the carrier-supplied Marshmallow. Carrier is Tesco Ireland which I think is reselling the O2 network. Anyway the phone is completely standard in that respect, not even rooted, no custom ROMs or bootloader.

Edit: It may have just done an OTA update, as at some points it would start into the 'optimizing apps' sequence and get a certain number of apps into that, then reset again.

She had problems last week with it restarting itself and getting into some sort of boot loop. Sometimes it would just restart to the initial Samsung A5 logo screen, sometimes would start the animated 'Samsung' loading screen, and then restart again.

Initially I wiped first the cache then cache+data via the recovery menu, to no avail. It didn't seem like a battery or other hardware issue as it would quite happily sit in the recovery menu for any length of time. 

As it's still under Samsung warranty I brought it in and got it back in a few days wiped and with Marshmallow on it. 

She then went about reinstalling all her apps and that evening had it charging when it started into the reboot cycle again. The last app she had put on was the FitBit app. Eventually got it to start and removed the FitBit app and it has been OK since.

My question is - I can understand how an app could affect a successful boot later on in the process but could it affect things so that the phone won't even get past the initial switch-on splash screen which I assume is in the firmware?
Apps start only after successful boot of Android OS. There is no way in Android app can start before or while booting.

Your case looks unclear to me. The issue has to be of a system app.

Did you phone had a software update recently?