E signature envelope, this is modeled by means of Point Distribution Models (PDMs) or the Active Shape Model (ASM) and consists of a mean signature shape and a number of eigenvectors to describe the main modes of variation of the shape [44]. The ASM is built as follows: Using N different signatures, each is converted into black and white by means of Otsu’s threshold and the salt and pepper noise is removed. Each image is morphologically dilated with s11606-015-3271-0 a A-836339 price square structuring element. The envelope is the contour of the dilated signature. All the contours are aligned by moving their geometrical center to the coordinate origin. From each contour we select n equidistant points called landmarks so as to obtain s s s s s s the vector xs ?fx1 ; x2 ; . . . ; xn ; y1 ; y2 ; . . . ; yn g, where is ; yis ?are the coordinates of the ith landth s s s s mark of the s contour. The first landmark 1 ; y1 ?is the one that satisfies y1 ?0 and x1 > 0. PN s The LDN193189 web average envelope is calculated as: x ?1=N i? x . The ASM captures the statistical features assuming that the point cloud xs, s = 1,. . ., N is a 2n dimensional ellipsoid which is obtained by applying principal component analysis (PCA). The 2n ?2n covariance matrix is calculated as: S?N 1X s T ?x xs ?x ?N s???The principal axes of the ellipsoid are described by the eigenvectors pk, k = 1,. . .,2n of S and the length of its axis is related to the eigenvalues k ! k+1, k = 1,. . .,2n. A new envelope can be modeled using the mean shape and a weighted sum of these deviations obtained from the first l modes as follows: xf ?x ?P ?b ??Pl P2n where P = (p1,. . ., pl) and l is such that k? lk 0:98 k? lk , and b = (b1,. . ., bl) is the vector of weights which are obtained randomly with a uniform distribution of mean zero and deviapffiffiffiffi tion equal to jbk j < 4 lk for each vector component. In the case of features with discrete values, the number of occurrences of each feature was manually counted for the databases to compute their occurrence probability. Each feature was L validated from about 200 signatures extracted from the databases. Let X ?fxi gi? be the L available values of a given feature of M possible values. The occurrence probability of each value is worked out as p(xi) = #xi 2 X/L, # meaning the number of times. In the case of features with continuous values, e.g. the skew, jir.2013.0113 the values of such a feature was manually obtained using the databases and their probability density function (pdf) estimated L by the histogram non-parametric method [45]. Let fxi gi? be the L available values of the given feature such that the range of this variable, range(x) = max(x) – min(x). This is divided into M intervals or bins of width h, which is chosen to obtain a number of intervals M = range(x)/h around L/50 to obtain a good statistical significance for each bin. The histogram is worked out as: hist(n) = #x 2 binn 1 n M. To generalize the estimated histogram, it is smoothed forPLOS ONE | DOI:10.1371/journal.pone.0123254 April 10,6 /Modeling the Lexical Morphology of Western Handwritten Signatureseach bin using a 3-point moving average filter as follows: shist(n) = PDFi = mediann – 1 l n and the density is estimated as p(xjx 2 binn) = shist(n)/L ?h. When M > 4, a parametric procedure is also applied to estimate a further probability density function. This parametric procedure relies on the Generalized Extreme Value (GEV) distribution [46] which is used when the feature distribution does not fit the Ga.E signature envelope, this is modeled by means of Point Distribution Models (PDMs) or the Active Shape Model (ASM) and consists of a mean signature shape and a number of eigenvectors to describe the main modes of variation of the shape [44]. The ASM is built as follows: Using N different signatures, each is converted into black and white by means of Otsu’s threshold and the salt and pepper noise is removed. Each image is morphologically dilated with s11606-015-3271-0 a square structuring element. The envelope is the contour of the dilated signature. All the contours are aligned by moving their geometrical center to the coordinate origin. From each contour we select n equidistant points called landmarks so as to obtain s s s s s s the vector xs ?fx1 ; x2 ; . . . ; xn ; y1 ; y2 ; . . . ; yn g, where is ; yis ?are the coordinates of the ith landth s s s s mark of the s contour. The first landmark 1 ; y1 ?is the one that satisfies y1 ?0 and x1 > 0. PN s The average envelope is calculated as: x ?1=N i? x . The ASM captures the statistical features assuming that the point cloud xs, s = 1,. . ., N is a 2n dimensional ellipsoid which is obtained by applying principal component analysis (PCA). The 2n ?2n covariance matrix is calculated as: S?N 1X s T ?x xs ?x ?N s???The principal axes of the ellipsoid are described by the eigenvectors pk, k = 1,. . .,2n of S and the length of its axis is related to the eigenvalues k ! k+1, k = 1,. . .,2n. A new envelope can be modeled using the mean shape and a weighted sum of these deviations obtained from the first l modes as follows: xf ?x ?P ?b ??Pl P2n where P = (p1,. . ., pl) and l is such that k? lk 0:98 k? lk , and b = (b1,. . ., bl) is the vector of weights which are obtained randomly with a uniform distribution of mean zero and deviapffiffiffiffi tion equal to jbk j < 4 lk for each vector component. In the case of features with discrete values, the number of occurrences of each feature was manually counted for the databases to compute their occurrence probability. Each feature was L validated from about 200 signatures extracted from the databases. Let X ?fxi gi? be the L available values of a given feature of M possible values. The occurrence probability of each value is worked out as p(xi) = #xi 2 X/L, # meaning the number of times. In the case of features with continuous values, e.g. the skew, jir.2013.0113 the values of such a feature was manually obtained using the databases and their probability density function (pdf) estimated L by the histogram non-parametric method [45]. Let fxi gi? be the L available values of the given feature such that the range of this variable, range(x) = max(x) – min(x). This is divided into M intervals or bins of width h, which is chosen to obtain a number of intervals M = range(x)/h around L/50 to obtain a good statistical significance for each bin. The histogram is worked out as: hist(n) = #x 2 binn 1 n M. To generalize the estimated histogram, it is smoothed forPLOS ONE | DOI:10.1371/journal.pone.0123254 April 10,6 /Modeling the Lexical Morphology of Western Handwritten Signatureseach bin using a 3-point moving average filter as follows: shist(n) = PDFi = mediann – 1 l n and the density is estimated as p(xjx 2 binn) = shist(n)/L ?h. When M > 4, a parametric procedure is also applied to estimate a further probability density function. This parametric procedure relies on the Generalized Extreme Value (GEV) distribution [46] which is used when the feature distribution does not fit the Ga.