Line follower optimization

Hello im trying to optimize my robot and i have come across this sort of navigation using matlab{ https://www.youtube.com/watch?v=TXNXz6areXA&t=1s&ab_channel=hidejr1053 } i cant find anything on this. If anyone has done this before can i get the resources(documentation) to achieve this?

Describe your observation and your expectation.

For help with robot navigation, please describe what you want the robot to do. If it is just "line following", what are you trying to optimize?