D.W.
I completely disagree with 90% of the responses.
My experience is a little different. My cancer diagnosis came 1 day before my son's 2nd birthday, 2 days before mine and before my daughter had turned 11 weeks-old. She spent every night of that first year in bed with me for a few reasons.
1. I had to stop nursing to start chemo. It was easier on me (I worked full-time through chemo) to have her there for nighttime feedings
2. I was scared of dying and my children not knowing me. I needed the comfort as much as she did as an infant.
She's our rock-solid sleeper now at 2 years old.
Her 4 year-old brother is an awful sleeper despite having a much different kind of "training" his first few years.
It's been 2.5 weeks for a MAJOR event in both of your lives.
He's scared, you're scared. 4 months from now is a different story. Yes, you can slowly transition him. You can start with the mattress at the end of the bed and create a reward system for staying there vs. coming into bed and slowly transition him back to his.
As adults, we have a different perspective on life. He's 4. He's had brain surgery. He doesn't understand anything other than he's scared and needs comfort and nurturing.
Good luck - sorry to have a different perspective.