#### Abstract

This paper presents a stock selection approach assisted by fuzzy procedures. In this approach, stocks are classified into groups according to business types. Within each group, the stocks are screened and then ranked according to their investment weight obtained from fuzzy quantitative analysis. Groups were also ranked according to their group weight obtained from fuzzy analytic hierarchy process (FAHP) and technique for order preference by similarity to ideal solution method (TOPSIS). The overall weight for each stock was then derived from both of these weights and used for selecting a stock into the portfolio. As a demonstration, our analysis procedures were applied to a test set of data.

#### 1. Introduction

Presently, investors are more interested in investing in stocks and bonds than keeping their money in the bank because it yields a higher return. However, this higher return also comes with higher risk; investors may lose some of their investment, get a lower-than-expected return, or get a lower return than that from another type of investment. Therefore, they have to analyze a stock carefully before investing in it.

In addition to several established approaches to stock analysis—such as quantitative fundamental analysis, technical analysis, and stochastic analysis—new analytical tools have been developed and widely used including ones that are based on Brownian movement, fuzzy logic, and the analytic hierarchy process.

The analytic hierarchy process (AHP) is a multicriteria decision-making approach and is a structured technique for organizing and analyzing complex decisions, based on mathematics and psychology. It was developed by Saaty in the 1970s, to help one make decision when one is faced with the mixture of qualitative, quantitative, and sometimes conflicting factors that are taken into consideration. AHP has been very effective in making complicated, often irreversible decisions. It has been extensively studied and refined since then (e.g.,  and references therein).

Fuzzy sets and fuzzy logic, especially, are of wide interest today. They are effective tools for modeling, in the absence of complete and precise information, complex business, finance, and management systems. The subjective judgement of experts who have used fuzzy logic techniques produces better results than the objective manipulation of inexact data. The concept of a fuzzy set is a reflection of reality reflection which serves as a point of departure for the development of theories which have the capability to model the pervasive imprecision and uncertainty of the real world. As applied to stock analysis (e.g.,  and references therein), fuzzy logic uses integrated experiential knowledge of human experts to make better quantitative estimates, not possible with classical logic, based on robust mathematical principles.

By reason of vagueness of boundaries of stock data in future and the attendant imprecision, uncertainty, and preference of decision makers, therefore, fuzzy logic and AHP seem suitable for this problem. This paper proposes an approach to stock analysis based on calculated weights from fuzzy quantitative analysis and fuzzy multicriteria decision making. The idea of using fuzzy quantitative analysis and fuzzy multicriteria decision making to imply final investment weights for the stock selection into portfolio is different from the previous works. The practicality of the approach was demonstrated by an application to a test set of data.

#### 2. Preliminaries

##### 2.1. Fuzzy Logic: Application and Definitions

Fuzzy logic was introduced by Zadeh  and has been widely applied to problems in various fields of study. Many researchers used fuzzy logic in stock market analysis (e.g., ) and decision making (e.g., [14, 6, 7, 915, 17]). In this study we use fuzzy logic in both, stock market analysis and decision making.

In this subsection, definitions of the fuzzy logic terms and concepts used in this study are described below.

Definition 1. Given a crisp set of a universe , a fuzzy set on is defined asand is a membership function.

Definition 2. Given a fuzzy set , an -cut set, denoted by , for all , is defined as

Definition 3. Let be a fuzzy set under the membership , and is a fuzzy number if it satisfies the following conditions: (1) is a normal fuzzy set; that is, , .(2) is a convex fuzzy set; that is, , , .(3)For every , for some closed interval .

Given an fuzzy number space, condition (3) of Definition 3 ensures that every can be represented by a closed interval , where are functions that satisfy the following conditions:(1) is a bounded, left continuous, and nondecreasing function on .(2) is a bounded, right continuous, and no-increasing function on .(3) for all .

Definition 4. is a positive fuzzy number that can be represented by the expression , if .

Definition 5. Given , a trapezoidal fuzzy number is a fuzzy number whose membership function is defined byand represented by the expression .

Definition 6. A trapezoidal fuzzy number is called a triangular fuzzy number and expressed as .

Note. For any real number , .

Definition 7. Given any two positive fuzzy numbers and and a real positive number , operations , ,, and between and and an operation between and are defined as follows:

Definition 8. Given two trapezoidal fuzzy numbers and , the distance between and represented by the symbol is defined asFor convenience, is defined for further use in this paper.

Definition 9. is a fuzzy matrix if are fuzzy numbers for all and .

Definition 10. is a fuzzy vector when all , are trapezoidal fuzzy numbers. The aggregation of , represented by , is defined as

##### 2.2. Consistency Fuzzy Matrix

In this subsection, we introduce the definition of consistency fuzzy matrix and consistency index which was developed by Ramik [3, 4].

Definition 11. Let be an matrix where for all and is a reciprocal matrix if for all .

Definition 12. Let be an matrix where for all and is a consistency matrix if there exist weight vectors , , for all , where and for all .

Definition 13. Let be an fuzzy matrix where are fuzzy numbers for all and is a reciprocal fuzzy matrix if for all .
In particular, if every member of is a triangular fuzzy number , is a reciprocal fuzzy matrix if for all .

Definition 14. Let be an fuzzy matrix, where for all and is a consistency fuzzy matrix if there exist for all and some with which is a consistency matrix; that is, there exist , , for all , where and for all .

According to Definition 14, since for all , there exist fuzzy vectors , where for all . These vectors are called fuzzy weight vectors.

It is clear that if is a fuzzy consistency matrix then it is a fuzzy reciprocal fuzzy matrix and is not a fuzzy consistency matrix if it is not a fuzzy reciprocal fuzzy matrix. Because of these reasons, construction of a fuzzy consistency matrix usually starts by first constructing a reciprocal fuzzy matrix . Ramik and Korviny  proposed a method for calculating fuzzy weight vector for a fuzzy reciprocal matrix , where for all by using the method of geometric mean. are defined for all , where

In addition, Ramik and Korviny  defined a consistency index for measuring the nearness of a fuzzy reciprocal matrix to the corresponding fuzzy consistency matrix as follows.

Definition 15. Let be a fuzzy reciprocal matrix, of which are triangular fuzzy numbers, evaluated from a scale for some real number ; the consistency index of represented by the symbol is defined as where are fuzzy weight vectors and for all as expressed in (7) andIf the consistency index , the fuzzy reciprocal fuzzy matrix is absolutely consistent. The closer the value of to 0 is, the more consistent the matrix is. Generally, an acceptable value is or 10%.

Theorem 16 (see ). If is an fuzzy reciprocal matrix with triangular fuzzy elements evaluated with the scale for some , then .

##### 2.3. Financial Ratios

A sustainable investment and mission requires effective planning and financial management.

The quantitative stock analysis is a useful tool that will improve investment’s understanding of financial results and trends over time and provide key indicators of organizational performance. Investor may use the quantitative stock analysis to pinpoint strengths and weaknesses of each company that impact to its stock.

The quantitative stock analysis presented in this study is based on the following financial ratios: price to earnings ratio or Ratio; price to book value ratio or Ratio; and price to intrinsic ratio or Ratio, which are defined as follows.

Definition 17. Let , , and be the number of common stock, preferred stock, and treasury stock respectively, current price per share, and -quarter net profit; price to earnings ratio or is defined as denotes the stock price per 1 baht of net profit that the investor is willing to pay for.

Definition 18. Let be the number of be the number of registered share, and the asset and liability of the company respectively, and current price per share; price to book value ratio or is defined aswhere .
denotes how many times the current stock price is compared to its account value.

Definition 19. Let be the reference interest rate, the year-end dividend per share, , and the -quarter historical price; the current target price is defined as

Definition 20. Let be the current target price and the current stock price; is called price per target price ratio represented by the symbol .
denotes how many times the current stock price is compared to the current target price.

#### 3. Stock Selection Procedure

This section presents the proposed stock selection procedure which is done in the following 3 main steps.

Step 1. The first step is analysis of individual stocks within each industrial group from their financial ratios, using fuzzy logic principles to calculate the investment weight for each individual stock.

Step 2. The second step is analysis of industrial groups (e.g., finance, communication, technology, and property) using fuzzy multicriteria decision-making principles to calculate the investment weight for each industrial group.

Step 3. The third step is analysis of individual stocks across all industrial groups using the 2 types of weights from Steps 1 and 2 to calculate the final weight for ranking all individual stocks in the market.

##### 3.1. Step 1: Analysis of Individual Stocks within Each Industrial Group

In this step, we apply the method of Bumlungpong et al.  to analyze individual stocks within each industrial group. Price to earnings ratio ( ratio), price to book value ratio ( ratio), and price to intrinsic value ratio ( ratio) are used to calculate the investment weight for each individual stock within an industrial group based on quantitative fuzzy analysis under these assumptions:(1)A calculated investment weight of an individual stock can be compared only to another one in the same industrial group.(2)More recent data reflect current trend better than earlier ones.(3)Fuzzy rules are flexible and depend on expert information.The specific steps of the fuzzy analysis are as follows.

Step 1.1. This step involves screening in only individual stocks () in the same industrial group of which sufficient financial data are provided for calculating , , and of earlier years up to the present.

Step 1.2. This step involves calculating , , and for all and , where denotes the stock in the year.

Step 1.3. This step involves calculating the following weighted arithmetic mean: , , and , , from the following equations:

Step 1.4. This step involves an expert constructing fuzzy sets in linguistic terms of the ranked financial ratios , , and and a fuzzy set of the investment weights from , , and , .

Step 1.5. This step involves an expert constructing fuzzy rules for estimation based on the fuzzy sets constructed in Step 1.4. These fuzzy rules are in the form of an “if-then” rule as follows:Rule-1: if is and is and is then is .Rule-2: if is and is and is then is .Rule-: if is and is and is then is ., , , and are fuzzy variables of , , , and , respectively, and , , and , , are linguistic terms of , , , and , respectively; that is, , , , and .

Step 1.6. This step involves importing , , and of the latest day and making estimation with Mamdani method using the fuzzy rules constructed in Step 1.5 hence obtaining an output of a fuzzy set under the membership on .

Step 1.7. This step involves performing defuzzification of the fuzzy output to a crisp output by a centroid method. A crisp is the average weight of the weight at each point on domain where for all ; that is, the crisp output is . It is the investment weight of each individual stock in a particular industrial group. These weights are then used to rank stocks in an industrial group.

##### 3.2. Step 2: Analysis of Industrial Groups

Industrial groups are ranked by weights calculated by the method of fuzzy multicriteria decision-making consisting of AHP, fuzzy analytic hierarchy process, and Fuzzy Technique for Order Preference by Similarity to Ideal Solution Method (FTOPSIS).

AHP is a method for calculating decision weights developed by Saaty  and Paul Yoon and Hwang . It compares paired data that are metrics of real quantities such as price, weight, and preference. Here, these quantities are preferences. Levels of preferences are represented by numbers in a set expressed as a reciprocal matrix. Generalizing this idea, the set of crisp preference values is replaced by a set of fuzzy preference values , where = and for all and .

The other technique, FTOPSIS developed by Chan  and Balli and Korukoglu , is a fuzzy technique for ranking preference levels by comparing the similarity of alternate choice to the ideal choice in order to find the best alternative. It covers diverse alternate choices, decision criteria, and decision makers.

Applying this technique to decision makers, decision criteria, and industrial groups as alternate choices, the analysis steps are as follows.

Step 2.1 (finding weights for decision makers). In this step, a decision maker , , is compared to another decision maker in terms of their preference level based on a preference function defined asThe decision maker’s preference matrix is a reciprocal matrix where

Step 2.2 (finding a fuzzy weight vector for ). is a fuzzy weight vector for all where withIf its consistency index as defined in Definition 15 is less than 0.1, it is accepted as being valid. Otherwise, the decision maker’s weight is reevaluated by repeating Step 2.1.

Step 2.3. This step involves decision makers constructing decision criteria for evaluating industrial groups , where , is constructed from investment weight of individual groups given by decision makers in the term of linguistic terms (see Table 1).

The decision criteria constructed are in the form of a fuzzy matrix with members , , , and , which are trapezoidal fuzzy numbers representing the linguistic terms of shown in (19).

Decision Criteria for Evaluating Industrial Groups . Consider

Step 2.4. This step involves decision makers evaluating decision criteria constructing from the linguistic terms as in Step 2.3. A fuzzy matrix for evaluation is then obtained where for all and as shown in (20).

Evaluation of Decision Criteria . Consider

Step 2.5. This step involves calculating decision criteria based on decision makers’ weights by multiplying the decision criterion of a decision maker in each column in Step 2.4 (depicted in (20)) with the corresponding decision maker’s fuzzy weight vector , where calculated from Step 2.2. Equation (21) shows these multiplication results.

Decision Criteria Based on Weights of Decision Makers. Consider

Next, we multiply the decision criterion for evaluating industrial groups in the column representing each decision maker constructed in Step 2.3 with the corresponding decision maker’s fuzzy weight vector , where calculated from Step 2.2. The multiplication results are in (22).

Decision Criteria for Evaluating Industrial Groups Based on Weights of Decision Makers. Consider

Step 2.6. This step involves aggregating weights of decision criteria based on the decision makers’ weights as follows:where , , , for all , , and is the number of decision makers. Equation (24) shows these aggregation results.

Weights of Decision Criteria . Consider

Next, we aggregate industrial groups based on the decision makers’ weights (see (22)) by the following equations:where , , , for all , , , and is the number of decision makers. These results are shown in (26).

Evaluation Matrix of Industrial Groups . Consider

Step 2.7. This step involves constructing a decision matrix by normalizing the industrial groups’ evaluation matrix (see (26)) as follows: Then, multiplying the normalized matrix with the decision weights from Step 2.6, , where and when .

Industrial Groups’ Evaluation Matrix. Consider

Step 2.8. This step involves defining positive ideal solution and negative ideal solution from (28) as and , respectively, where and , .

Step 2.9. This step involves calculating the distances between the industrial groups’ evaluation results with the positive and negative ideal solutions, as defined by the following:where are calculated in the same way as fuzzy numbers are calculated according to Definition 8 (depicted in (30)).

Distances between the Industrial Groups’ Evaluation Results and Positive and Negative Ideal Solutions and . Consider

Step 2.10. This step involves calculating the nearness coefficients to the positive ideal solution, , and ranking the industrial groups according to them. are defined as follows:

From the calculation, a set of investment weights for industrial groups, , where are weights of individual groups, is obtained. The industrial group of which investment weight value is nearest to one (the closest to the positive ideal solution) is the best industrial group.

##### 3.3. Step 3: Analysis of All Stocks from Different Industrial Groups

In this step, the Correlation-Product Implication is used; the two investment weights from Steps 1 and 2 are used to calculate the integrated final investment weights for all of the stocks in the market, denoted as , where and are the weight of the stock from the group from Step 1 and is the weight of the group from Step 2. These weights are then used to rank the stocks for making decisions and planning out strategies.

#### 4. Application of the Analysis Procedures to a Demonstration Case

As a demonstration of the applicability of our analysis procedures, a simulated case of stock selection into a portfolio for a given period of time was conducted. Suppose that the 6 industrial groups of investment interest were the following: agricultural and food industry (), consumer product and service industry (), financial industry (), industrial product and technology industry (), property and construction industry (), and resource industry (). Stocks from each individual industry were analyzed as follows.

Step 1 (analysis of stocks in an industrial group). As an example, the analysis of the property and construction industry, , is shown below.

In this group, , we use the past 5-year financial fact data of the companies from Stock Exchange of Thailand, 2010–2014, http://www.settrade.com/.

Step 1.1. This step involves gathering the past 5-year financial data of the companies in this group and screening in stocks with complete data from 12 companies: CK, CNT, ITD, NWR, PREB, SEAFCO, STEC, STPI, SYNTEC, TRC, TTCL, and UNIQ.

Step 1.2. This step involves calculating the , , and values of each individual stock.

Step 1.3. This step involves calculating the following weighted arithmetic mean of , , and . Tables 2, 3, and 4 show data of some stock (STPI), and Table 5 shows the weighted arithmetic mean of each individual stock in .

Step 1.4. This step involves an expert constructing a fuzzy set based on the latest 5-year financial data of which linguistic terms are represented by trapezoidal and triangular fuzzy numbers.

Values of , , and were grouped into 3 levels: low (), medium (), and high (), and so the fuzzy sets representing these levels wereThe fuzzy sets of linguistic terms were as follows:, , ., , ., , .

Step 1.5. This step involves an expert constructing fuzzy rules from the fuzzy sets constructed from Step 1.4 as follows:Rule 1: if was and was and was then was .Rule 2: if was and was and was then was .Rule 27: if was and was and was then was .

Step 1.6. This step involves importing the values of current (inversing to ), , and , which, in this study, were the values of the 22nd of January 2015 shown in Table 6.

Note. The s of CNT and NWR were not applicable, meaning that they suffered a loss, so they were not included in further calculation.

Step 1.7. This step involves performing defuzzification of the fuzzy output values to crisp values with the centroid method, obtaining the investment weights shown in Table 7.

For the purpose of easy demonstration, the investment weights of the stocks from the other 5 industrial groups were made up. All of the weights are tabulated in Table 8.

Step 2 (analysis of industrial groups). Stocks from 6 industrial groups, , were analyzed. Three decision makers, , , constructed 4 decision criteria, , , , , calculated in the following steps.

Step 2.1. This step involves calculating the weights for decision makers. The preference level of the decision maker was compared to that of the decision maker with a scale , obtaining

Step 2.2. This step involves calculating the fuzzy weight vectors, , for , and obtaining the following respective vectors for decision makers : , , and , and a consistency index .

Step 2.3. This step involves the 3 decision makers, , , evaluating 6 industrial groups, , according to the decision criteria , , , utilizing linguistic terms represented by trapezoidal fuzzy numbers as in Table 9.

Step 2.4. This step involves decision makers , , evaluating the decision criteria , , , utilizing the linguistic terms represented by the mentioned trapezoidal fuzzy numbers as in Table 10.

Step 2.5. This step involves calculating fuzzy decision criteria and the evaluation criteria for industrial groups based on the weights of decision makers as in Tables 11 and 12, respectively.

Step 2.6. This step involves aggregating the decision criteria and the fuzzy evaluation of industrial groups based on the weights of decision makers. The aggregation results are shown in Tables 13 and 14.

Step 2.7. This step involves normalizing the weights of industrial groups for each decision criteria shown in Table 13 and then multiplying the normalized matrix with the weights of decision criteria from Step 2.6, defined by , where and , when , , to obtain a decision matrix shown in Table 15.

Step 2.8. This step involves stipulating a positive ideal solution and a negative ideal solution to be

Step 2.9. This step involves calculating the distances from the results of industrial groups evaluation in Table 14 to the and the ideal solutions shown in Tables 16 and 17, respectively.

Step 2.10. This step involves obtaining the nearness coefficients , , to the positive ideal solution and the investment weights shown in Table 18.

Step 3 (analysis of all stocks from different industrial groups). The two kinds of investment weights obtained from Steps 1 and 2 were used to calculate the final investment weights for all of the stocks in the market, , where represents the company and the industrial group, and the final weights were ranked as shown in Table 19.

From Table 19, investors can use the calculated weights to help with their decision-making and strategy-planning. The better stocks to invest in show higher final investment weights.

#### 5. Conclusions

The innovation appearing in this paper is to present the tactic of conveying the stock selection to portfolio by using two tactics, fuzzy quantitative analysis and fuzzy hierarchical analysis. The two tactics imply the final investment weight. Investors can determine their strategies by using the final investment weights. The final investment weights may be used to select stocks and allocate asset into portfolio. A case study presented in Table 19 shows that if we use the final investment weights as decision criteria to select stocks into portfolio, stock that has the highest weight is the most interesting and is chosen first. In contrast, stock that has the lowest weight is the least interesting and is chosen last. However, decision-making and strategy-planning of each investor may be different and depend on their financial risk tolerance. For example, some investors whose financial risk tolerance is high level maybe invest in only one stock with the highest final investment weights while some investors reduce risk by investing in many stocks with high final investment weights. You should keep in your mind that there is no best tool in the world for financial analysis but you can alter tools that fit for each situation. The purpose of this research is to construct the tool for financial analysis that may be an alternative for investors. At least, we hope that this research will help investors to make an appropriate decision.

For future work, we will improve our model and compare results with others in each situation. Moreover, the software of this model will also be provided.

#### Competing Interests

The authors declare that they have no competing interests.

#### Acknowledgments

The financial support for this study was from King Mongkut’s Institute of Technology Ladkrabang, Bangkok, Thailand.