It can be done in this way:
clear all
kg=tf([20],[1 2 0])
nupoints=1000;%finest reticule, best result
freq=logspace(-2,2,nupoints);
[mag1(1:nupoints),phase1(1:nupoints)]=bode(kg,freq);
mag=20*log10(mag1)
semilogx(freq,mag);%seeing the bode plot obtained
% by example I go to find a frecuence at which the magitude is 20dB
% for this we do interpolation over the obtained curve
hold on
desiredw=interp1(mag,freq,20)
plot(desiredw,20,'r+')% see the value
regards
nebisman