How to trace the edges on matlab
One possible pre-processing apporach is to use imdilate(I,strel('disk',5)) to thicken the road lines a little bit.

If you are trying houghlines, probably one parameter that you need to tune is the 'FillGap' which will connect the very short segments (you can try to change this parameter yourself to observe the effect, along with the MinLength value):

lines = houghlines(BW,T,R,P,'FillGap',30,'MinLength',15);


However, the road curves are not straight lines, so I won't recommend you to use hough transform. You may try bwmorph(bw,'skel',N); after you thicken the binarized road image. N is the iteration number that you need to tune.