Sorting symbols in 'List of Symbols'

Is there a way I can sort the symbols (in some logical order) automatically in my LaTeX draft? Presently they come in the order I am defining them.

\clearpage % Start a new page
$y$ & State variable\\
$\mathbb{R}$ & Real space\\
$\bf{x}$ & Vector of training indipandent variables\\
${\mathbf{x}'}$  & Vector of testing indipandent variables

• don't use \bf. it's deprecated. also check the answer in this thread: tex.stackexchange.com/questions/348640/… – naphaneal Jun 6 '18 at 9:40
• Please provide a minimal working example (MWE) that illustrates your problem. Reproducing the problem and finding out what the issue is will be much easier when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Troy Jun 12 '18 at 23:57