Portfolio optimization aims to protect investors against any risks which they may experience. Stock diversification is one of the solutions to optimize stock portfolio, where a diverse portfolio tends to have less risk than the undiversified one. Agglomerative clustering is a hierarchical clustering method. Applying diversification concept, agglomerative clustering is used to cluster 40 different assets based on their financial ratio scores (Current Ratio, Debt-Equity Ratio, Profit Margin, Return on Equity, Price/Earnings per Growth, EPS diluted, and Price/Earnings Ratio). Genetic algorithm is search method based on principles of natural selection and genetics. After the stocks are clustered, Genetic algorithm with heuristic crossover is applied to each cluster alongside to determine the proportion of each stock. In this paper, a possibilistic mean-semi-absolute deviation optimization model is used where cardinality, quantity, and transaction cost are considered as constraints. We also use the assumption that the returns of risky assets are fuzzy numbers. The implementation shows that the method gave a higher level of return (29.77 %) and Sharpe's ratio (18.71) compared to S&P 500 index in the same period of time (12.34 % and 2.7 respectively).