Yes, z = wx + b. The y values are plotted, they are sigmoid(z). The best w and b values are learned via gradient descent, starting from the initial w and b values.