Any theoretical dollar neutral portfolio, we technically wouldn’t be using any cash to create the positions. In fact, sometimes, in academic papers, they call these portfolios, zero investment portfolios. In real life, there are transaction costs, margin costs for shorting positions, and differences in timing of trades. For the theoretical portfolio used to evaluate a factor, let’s not worry about those issues. So, now, let’s visualize how we convert a portfolio into a dollar neutral portfolio. Let’s say we have some portfolio weights and want to adjust them so that they are dollar neutral. For example, let’s say we have two stocks in the portfolio, the weights are both positive, so the portfolio is not dollar neutral. If you imagine the weights as actual weights on a balancing scale, the scale would be tilting because it’s heavier on the positive side compared to the negative side. Notice that the relative difference between these two stocks is the weight of A minus the weight of B. Keep this in mind for what’s coming next. If we were to shift the weights to the left towards the negative direction, we can keep going until the weights are balanced. Notice that the relative difference between the weights of the two stocks is still the same. So, how did we shift our weights to make the portfolio dollar neutral? Well, we actually took the average of the weights and then subtracted that average from each of the weights. Does this look familiar to you? Subtracting the mean of the weights, D means the portfolio weights. The sum of the resulting weights now equals zero. So, the portfolio is dollar neutral.