If you want to cancel your node and have yet to receive your reward distribution, will you still get your reward that accumulated while staking prior to canceling? No.
The reason for this is that the payouts are very linear, and are based on the positioning the counter is looping through for all nodes.
For example, if your node is in position 100, and the "Next Reward Index" on the Masternode Stats tab of the Hoard Explorer is showing 99 when you cancel your node, you will not be credited with any rewards as you have cancelled prior to distribution meaning the index will simply move on to the next node in the list.
Additional information about earning rewards can be found in the following article: