## 4 Results
### Linear Regression  
Linear Regression is one of the most common methods for analyzing various variable relationships. This method aims to predict the value that a dependent variable will exhibit after considering the independent variables' values. The results of this procedure are then analyzed using the coefficients. Linear Regression can be performed in Spark using the MLlib library. However, before it can be performed, it is necessary to convert the data into numerical format using OneHotEncoder and StringIndexer. Furthermore, the VectorAssembler tool created a single feature vector for all the features. The Python code was also used to conduct a Linear Regression analysis using Cassandra data through Apache Spark (Table A10). The results are illustrated in the following three graphs. The first graph (Figure 6) shows the parameters influencing fish mortality, displaying the coefficients of various features in the Linear Regression model used for prediction, focusing on \"conductivity\" and \"DO\". Each bar represents a feature's coefficient value, reflecting its impact on the model's predictions. Notably, \"SFR\" and \"DO\" exhibit significant coefficient values, indicating a stronger influence on the model's output than other features. In the second graph, the x-axis scale is adjusted to enhance the readability of smaller coefficients, allowing their relative influence to stand out more clearly (Figure 7). This focused view highlights the minor but noteworthy contributions of features such as \"i.f\", \"food\", and \"MAB\" in the Linear Regression model, providing a more detailed perspective on how these variables impact fish mortality predictions. The third graph shows the outcomes of the Linear Regression procedure (Figure 8). Figure 8 illustrates the relationship between predicted and actual values. A perfect forecast is when the predicted values are like the actual ones. Although these coefficients show that each of these elements impacts fish mortality, the magnitude of their effects varies. A brief analysis of the coefficients for each variable of the model's Linear Regression framework is provided. These coefficients indicate that each of these variables has some effect on fish mortality (Table 6) [34; 35; 36; 37; 38]. Figure 6: _Linear Regression_-predicted factors affecting fish mortality. Figure 8: Linear regression predictions versus true values for BS fish. Figure 7: Factors of coefficient scale fish mortality. * _Dissolved Oxygen (DO)_ (24,853): the positive coefficient of \(DO\) (24,853) suggests that there is a link between the increasing levels of this element and the mortality rate. * _i_f_ (0.290): The increase in fish concentration is also linked to an increased mortality rate. However, the effect is not as strong as with \(DO\) (Table 6). * _Food_ (0.154): the food factor indicates that increased food quantity leads to higher mortality rates (Table 6). * _MAB_ (0.024): the small but positive relationship between the _MAB_ and mortality rates suggests that higher atomic weights may contribute to increased deaths. * _Vol_ (0.004): the effect of the fish volume on mortality in each space is small. * _Value_ (0.001): the small positive effect of the value indicates that the relationship between the parameter and mortality rates is not strong (Table 6). * _Fishno_ (0.0001): the minimal effect of the _Fishno_ variable on mortality is shown. * _Food Model_ (\(-\)0.080): the Food Model has a negative effect, indicating that certain kinds of food can help reduce fatalities. * _Temp_ (\(-\)2.139): the negative effect of temperature is shown, suggesting that increased temperatures can reduce the mortality rate. * _Conductivity_ (\(-\)24,853): The relationship between conductivity and mortality is negative. This indicates that elevated conductivity can reduce the mortality rate. * _SFR_ (\(-\)939.007): the relationship between the _SFR_ and mortality is negative, indicating that higher values can substantially reduce mortality (Table 6).