# Decision-Tree-Based Horizontal Fragmentation Method for Data Warehouses
## 4 Results and Discussion
### Application of FTree in the Tourist Data Warehouse
\begin{table}
\begin{tabular}{l c} \hline
**Query** & **Frequency** \\ \hline \(q_{1}\): SELECT month, sum(booked\_rooms) FROM time, hotel\_activity WHERE & 3 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2007 GROUP BY month; & 4 \\ \(q_{2}\): SELECT month, sum(booked\_rooms) FROM time, hotel\_activity WHERE & 2 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2008 GROUP BY month; & 5 \\ \(q_{3}\): SELECT month, sum(booked\_rooms) FROM time, hotel\_activity WHERE & 2 \\ time.id\_time=hotel\_activity.id\_time AND time.quarter=\(\text{T}1^{\prime}\) GROUP BY month; & 5 \\ \(q_{4}\): SELECT month, sum(tourist\_night) FROM time, hotel\_activity WHERE & 2 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2009 GROUP BY month; & 5 \\ \(q_{5}\): SELECT quarter, sum(tourist\_night) FROM time, hotel\_activity WHERE & 2 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2010 GROUP BY quarter; & 3 \\ \(q_{6}\): SELECT year, sum(tourist\_night) FROM time, hotel\_activity WHERE time.id\_time=hotel\_activity.id\_time & 4 \\ AND time.quarter=\(\text{T}2^{\prime}\) group by year; & 5 \\ \(q_{7}\): SELECT month, sum(tourist\_arrivals) FROM time, hotel\_activity WHERE & 6 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2011 group by month; & 5 \\ \(q_{8}\): SELECT year, sum(tourist\_arrivals) FROM time, hotel\_activity WHERE & 7 \\ time.id\_time=hotel\_activity.id\_time AND time.month=\(\text{`dic''}\) group by year; & 8 \\ \(q_{9}\): SELECT quarter, sum(tourist\_arrivals) FROM time, hotel\_activity WHERE & 9 \\ time.id\_time=hotel\_activity.id\_time AND time.year=2012 group by quarter; & \\ \hline \end{tabular}
\end{table} 
Table 13: OLAP queries executed in the tourist DW in the second experiment. Figure 7: Decision tree for 2 fragments found by FTree for the first experiment. Other classification techniques were used to select the fragmentation scheme. Table 14 presents the results of the evaluation metrics with naive Bayes and multilayer perceptron with one hidden layer with six units, sigmoid activation function, learning rate = 0.3, momentum = 0.2, and number of epochs = 500. The multilayer perceptron selected the same fragmentation scheme as FTree, while naive Bayes chose the scheme with three fragments. We compared the schemes using a cost model where the cost of a decision support query \(q_{i}\) is given by the irrelevant tuple cost (ITC) and the relevant tuple cost (RTC), as shown in Equation (2). \[Cost(q_{i})=ITC(q_{i})+RTC(q_{i}) \tag{2}\]  
The amount of irrelevant data accessed from a query is calculated by multiplying the number of irrelevant tuples accessed by the query in every fragment \(f\!r_{k}\) by the query frequency \(\langle f_{i}\rangle\). Equation (3) is used to obtain ITC where \(card(f\!r_{k})\) is the cardinality of the \begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline \multirow{2}{*}{**Scheme**} & \multirow{2}{*}{**Precision**} & \multicolumn{3}{c}{**Naïve Bayes**} & \multicolumn{3}{c}{**Multi-Layer Perceptron**} \\  & & **Recall** & **F-Measure** & **ROC Area** & **Precision** & **Recall** & **F-Measure** & **ROC Area** \\ \hline \(data\_set_{2}\) & 0.800 & 0.667 & 0.625 & 0.708 & **0.688** & **0.667** & **0.657** & 0.694 \\ \(data\_set_{3}\) & **0.857** & **0.750** & **0.742** & **0.750** & 0.563 & 0.583 & 0.570 & **0.733** \\ \hline \hline \end{tabular}
\end{table} 
Table 14: Comparison of the two schemes with Naive Bayes and Multi-layer Perceptron. Figure 11: Decision tree for 2 fragments found by FTree for the second experiment. Figure 10: Comparison of fragmentation schemes with 2 and 3 fragments. fragment \(f_{k}\), \(sel_{j}\) is the selectivity of the predicate \(p_{j}\), and \(rt_{j}\) is the number of tuples from the predicate \(p_{j}\) located in other fragments required to answer the query.