giniquintile <- function ( L ) #*****************************************************************************80 # ## giniquintile computes the Gini quintiles. # # Licensing: # # Copyright 2016 James P. Howard, II # # The computer code and data files on this web page are distributed under # https://opensource.org/licenses/BSD-2-Clause, the BSD-2-Clause license. # # Modified: # # 12 March 2020 # # Author: # # Original R code by James Howard; # Modifications by John Burkardt. # # Reference: # # James Howard, # Computational Methods for Numerical Analysis with R, # CRC Press, 2017, # ISBN13: 978-1-4987-2363-3. # { x <- c ( 0.2, 0.4, 0.6, 0.8 ) L <- x - cumsum ( L / 100.0 ) value <- 25.0 / 144.0 * ( 3.0 * L[1] + 2.0 * L[2] + 2.0 * L[3] + 3.0 * L[4] ) return ( value ) }