Zilefac Elvis
2015-Mar-06 01:49 UTC
[R] Fit an Extreme Value Distribution to List of dataframes R
Hello, I have a list object with many dataframes (example provided below). Each coulmn in a dataframe represents a simluation and each dataframe represents a clmate station. I want to fit an extreme value distribution on each coulmn of a dataframe and then average the confidence intervals and estimates of retruen values from all simulations in a dataframe. 1) I would like to apply the following code to each dataframe in the list. So far, I can apply 'fevd' to each column in a dataframe, NOT list. library(extRemes) out.lst <- lapply(lst, fevd,type="GEV",method = c("MLE"))# fit GEv to each column of dataframe #lapply(out.lst,plot) # make plots for all columns rlcis<-lapply(out.lst,return.level, do.ci=TRUE,method="normal",return.period=c(2,5,10,20,50,100))# calc return and CIs for all columns lst=list(df,df,df,df) df=structure(list(Sim001 = c(120.79, 59.35, 51.14, 104.85, 51.09, 138.91, 254.94, 56.44, 68.3, 51.69, 51.31, 51.08, 37.17, 38.02, 62.13, 111.48, 118.38, 45.54, 44.87, 49.59), Sim002 = c(50.25, 31.17, 67.48, 104.56, 59.82, 38.09, 50.76, 70.25, 35.8, 59.2, 47.89, 55.21, 74.38, 51.88, 124.09, 91.86, 109.28, 65.61, 69.54, 55.89), Sim003 = c(30.22, 50.07, 57.66, 57.97, 62.73, 43.84, 103.61, 53.05, 60.71, 46.57, 65.87, 33.27, 60.24, 43.63, 115.68, 37.24, 43.27, 46.38, 122.97, 86.02), Sim004 = c(38.6, 39.02, 45.74, 201.55, 110.78, 49.91, 63.5, 48.65, 94.43, 37.01, 32.61, 46.39, 120.25, 45.38, 70.26, 94.02, 67.35, 55.62, 59.3, 33.96 ), Sim005 = c(43.54, 68.42, 86.02, 78.9, 40.68, 59.97, 34.5, 48.47, 68.81, 32, 49.53, 51.23, 51.42, 61.17, 38.02, 52.96, 45.25, 39.18, 42.33, 97.15), Sim006 = c(45.96, 65.21, 94.81, 106.71, 46.95, 26.93, 39.45, 33.79, 50.36, 31.22, 128.37, 177.03, 82.07, 58.02, 32.5, 96.37, 73.77, 48.96, 143.52, 50.14), Sim007 = c(66.3, 53.99, 162.7, 100.22, 48.76, 74.06, 49.3, 62.66, 158, 82.57, 94.07, 93.01, 53.88, 160.91, 63.71, 44.93, 63.82, 56.7, 58.92, 101.52), Sim008 = c(130.62, 75.48, 126.46, 49.97, 71.69, 66.81, 89.33, 52.68, 29.19, 75.88, 89.69, 59.41, 84.16, 104.49, 65.04, 66.41, 88.5, 56.64, 62.48, 77.08), Sim009 = c(60.58, 71.85, 62.08, 57.4, 63.08, 45.38, 50.97, 59.42, 159.44, 120.94, 58.66, 54.57, 77.45, 49.63, 48.88, 91.03, 103.42, 56.9, 97.04, 69.89), Sim010 = c(48.63, 51.07, 65.13, 47.59, 94.73, 42.43, 68.77, 95.83, 42.16, 133.1, 67.2, 56.91, 138.57, 39.26, 79.75, 123.67, 64.27, 64.83, 78.88, 89.74), Sim011 = c(59.85, 53.73, 116.88, 95.06, 113.44, 87.64, 47.37, 42.42, 36.69, 39.11, 76.91, 59.85, 76.29, 118.37, 39.14, 50.76, 98.06, 40.71, 53.03, 42.93), Sim012 = c(128.35, 60.21, 60.19, 51.69, 51.47, 35.44, 101.72, 82.83, 50.72, 68.66, 80.84, 59.98, 79.84, 35.52, 128.69, 53.35, 84.77, 18.38, 28.98, 48), Sim013 = c(52.88, 117.11, 103.3, 103.59, 119.06, 62.66, 65.64, 75.91, 81.78, 80.31, 22.83, 79.22, 51.33, 79.63, 86.26, 54.44, 42.86, 63.95, 166.87, 58.48), Sim014 = c(50.28, 123.9, 35.87, 133.52, 94.28, 62.35, 58.54, 42.08, 67.7, 101.44, 34.68, 45.98, 60.99, 60.06, 79.76, 61.93, 59.4, 42.02, 56.45, 81.41 ), Sim015 = c(50.32, 39.01, 100.3, 105.38, 55.49, 36.36, 56.49, 107.52, 38.7, 73.09, 98.22, 44.19, 50.17, 56.69, 44.82, 44.09, 57.57, 52.55, 90.37, 78.62), Sim016 = c(35.2, 62.77, 35.25, 52.05, 93.51, 65.84, 43.85, 54.52, 39.17, 62.02, 47.6, 34.42, 190.57, 38.46, 94.9, 73.34, 78.5, 52.84, 103.7, 51.48 ), Sim017 = c(69.03, 58.19, 130.37, 80.04, 52.96, 65.14, 65.08, 45.95, 65.35, 41.95, 78.67, 78.41, 56.51, 63.52, 52.93, 52.32, 70.14, 81.59, 70.99, 105.02), Sim018 = c(55.98, 44.37, 59.07, 36.65, 44.16, 26.62, 125.38, 75.54, 75.46, 25.62, 22.95, 65.74, 72.86, 53.5, 32.05, 58.98, 70.87, 30.95, 78.25, 54.75), Sim019 = c(147.82, 37.48, 161.91, 46.28, 95.4, 74.79, 53.51, 58.73, 50.96, 32.03, 50.08, 60.03, 76.75, 45.31, 58.29, 52.91, 42.84, 74.52, 83.19, 43.8), Sim020 = c(59.33, 218.52, 64.55, 73.07, 59.9, 39.09, 129.88, 61.53, 56.7, 38.55, 62.2, 29.25, 52.74, 57.86, 46.04, 80.03, 44.61, 88.52, 45.36, 93.97 ), Sim021 = c(93.44, 41.32, 67.08, 99.15, 89.43, 31.64, 38.59, 65.08, 58.9, 52.7, 47.39, 47.91, 90.93, 54.57, 51.26, 44.59, 33.52, 38.69, 44.92, 50.46), Sim022 = c(43.37, 43.47, 63.15, 77.19, 117.13, 77.32, 65.36, 67.49, 49.18, 87.66, 70.09, 110.66, 70.85, 46.71, 55.36, 45.53, 30.55, 51.7, 46.08, 65.91 ), Sim023 = c(65.76, 42.75, 50.2, 58.23, 69.27, 75.63, 46.72, 72.47, 62.53, 50.87, 58.8, 63.61, 39.99, 91.36, 66.07, 100.32, 55.34, 32.59, 59.8, 43.96), Sim024 = c(174.2, 70.17, 47.86, 71.24, 91.39, 40.5, 28.66, 64.57, 33.02, 46.27, 68.56, 56.68, 97.28, 46.24, 65.76, 72.53, 60.26, 128.26, 85.63, 107.29), Sim025 = c(84.66, 38.95, 43.63, 41.33, 108.67, 62.94, 64.73, 57.26, 42.11, 100.24, 28, 35.95, 175.8, 61.64, 81.42, 67.55, 68.12, 35.1, 46.63, 105.43), Sim026 = c(64.17, 55.25, 59.21, 49.21, 104.75, 129.05, 76.05, 69.88, 110.19, 40.71, 103.17, 74.32, 64.18, 55.66, 105.93, 36.25, 81.08, 75.96, 81.67, 99.22), Sim027 = c(55.07, 53.32, 71.68, 37.51, 96.35, 42.25, 41.22, 41.09, 67.46, 69.64, 54.6, 37.63, 106.3, 121.53, 67, 24.6, 64.82, 64.82, 68.65, 98.26), Sim028 = c(56.44, 27.16, 45.64, 59.74, 55.09, 28.91, 94.48, 42.9, 91.21, 79.34, 41.06, 42.36, 57.21, 38.13, 46.28, 75.48, 83.1, 72.94, 98.49, 66.73 ), Sim029 = c(49.77, 49.29, 54.16, 83.52, 48.06, 61.06, 26.69, 68.11, 51.43, 56.84, 35.05, 87.57, 160.17, 48.4, 95.22, 74.41, 69.18, 43.84, 65.14, 65.05), Sim030 = c(63.45, 62.12, 81.56, 66.5, 53.21, 49.33, 44.95, 50.49, 81.7, 59.45, 46.68, 100.52, 128.92, 75.38, 74.2, 46.92, 96.02, 42.79, 73.97, 35.67), Sim031 = c(42.32, 44.08, 63.43, 74.42, 78.09, 59.41, 54.34, 103.51, 74.34, 42.34, 32.86, 76.19, 56.32, 79, 79.11, 37.75, 46.15, 43.67, 78.34, 115.33), Sim032 = c(60.6, 46.4, 179.78, 102.86, 57.86, 34.29, 68.26, 56.88, 103.82, 97.29, 56.46, 104.64, 58.03, 70.71, 53.61, 111.52, 77.73, 49.03, 48.64, 69.16), Sim033 = c(35.23, 42.14, 64.93, 74.66, 183.2, 26.87, 59.4, 73.74, 63.13, 37.65, 64.59, 45, 75.46, 78.81, 66.73, 56.63, 50.68, 56.87, 69.41, 86.37), Sim034 = c(51.52, 108.22, 47.16, 41.77, 62.01, 85.64, 66.62, 58.47, 167.55, 34.71, 73.55, 43.42, 122.87, 53.81, 48.08, 59.5, 83.6, 46.33, 55.82, 76.99), Sim035 = c(37.25, 41.93, 74.69, 61.38, 78.29, 70.13, 56.44, 36.66, 94.21, 97.32, 46, 45.78, 32.85, 57.05, 61.26, 69.1, 43.26, 41.41, 69.67, 147.57), Sim036 = c(67.96, 59.22, 65.29, 64.49, 41.23, 39.53, 46.21, 32.87, 88.47, 59.53, 44.28, 73.41, 38.3, 72.1, 77.33, 43.23, 99.6, 49.46, 63.7, 54.96 ), Sim037 = c(73.31, 60.02, 46.72, 69.75, 39.97, 42.39, 69, 70.86, 86.68, 79.96, 46.88, 43.91, 70.03, 53.46, 59.72, 112.63, 44.71, 91.34, 80.78, 58.28), Sim038 = c(66.82, 67.99, 72.85, 108.32, 45.14, 54.1, 68.67, 68.01, 51.8, 43.09, 43.94, 46.68, 61.19, 75.64, 74.25, 43.64, 114.62, 43.71, 43.1, 66.72), Sim039 = c(41.57, 39.89, 172.91, 45.93, 146.08, 64.04, 51.16, 60.84, 63.01, 59.85, 43.72, 118.3, 57.85, 64.73, 141.46, 48.84, 109.66, 53.85, 49.28, 33.75), Sim040 = c(41.66, 203.26, 29.55, 64.55, 43.06, 85.98, 89.09, 80.92, 83.08, 40.77, 47.7, 120.21, 88.37, 71.86, 86.6, 122.06, 59.61, 73.06, 67.51, 165.09), Sim041 = c(43.02, 33.99, 32.19, 60.84, 34.49, 31.81, 46.81, 56.2, 74.42, 59.62, 48.4, 53.33, 78.04, 100.36, 92.8, 147.88, 89.32, 38.73, 76.25, 93.83), Sim042 = c(64.27, 49.35, 99.48, 86.88, 24.19, 54.45, 111.73, 72.6, 57.73, 75.14, 42.85, 96.38, 55.17, 82.13, 72.9, 68.29, 76.44, 41.64, 83.17, 89.69 ), Sim043 = c(92.51, 127.4, 68.69, 45.07, 65.78, 40.81, 35.22, 41.47, 50.94, 73.3, 55.48, 91.55, 60.15, 39.31, 110.71, 73.27, 92.3, 64.83, 74.21, 57.68), Sim044 = c(46.86, 68.48, 51.29, 83.66, 87.2, 79.22, 62.5, 25.17, 44.04, 55.36, 69.23, 23.23, 43.22, 43.38, 34.28, 96.67, 42.1, 52, 95.03, 43.73), Sim045 = c(111.78, 63.81, 126.77, 49.3, 60.11, 42.84, 47, 22.98, 48.41, 144.18, 42.21, 85.14, 105.72, 86.97, 55.17, 73.22, 122.86, 60.04, 31.13, 95.21), Sim046 = c(43.29, 40.17, 53.99, 29.43, 87.25, 58.74, 81.31, 74.3, 48.47, 91.82, 60.84, 74.5, 94.22, 43.77, 55.42, 71.17, 54.49, 76.96, 58.04, 57.95), Sim047 = c(51.58, 50.48, 51.44, 38.82, 49.5, 59.16, 46.11, 43.95, 109.03, 57.92, 62.12, 68.25, 42.59, 82.52, 63.36, 84.1, 77.16, 183.01, 80.42, 57.06), Sim048 = c(39.95, 57.88, 33.13, 57.07, 123.89, 39.91, 94.86, 80.16, 104.46, 86.94, 87.65, 82.74, 69.6, 79.83, 32.9, 34.05, 45.11, 83.16, 78.13, 56.18), Sim049 = c(15.68, 65.54, 71.53, 148.3, 79.93, 49.64, 82.59, 34, 77.56, 92.19, 158.28, 82.13, 46.34, 93.22, 93.89, 59.37, 47.72, 40.11, 128.32, 67.29), Sim050 = c(37.63, 43.41, 143.61, 157.48, 39.44, 73.62, 75.41, 86.69, 58.29, 66.7, 45.95, 34.3, 61.8, 78.35, 58.18, 60.04, 84.08, 76.19, 70.58, 73.57), Sim051 = c(68.28, 50.97, 62.66, 45.23, 92.23, 93.46, 53.17, 108.31, 45.67, 121.95, 46.52, 66.13, 75.3, 42.31, 85.94, 77.72, 111.41, 57.23, 203.79, 68.42), Sim052 = c(86.42, 75.88, 57.99, 72.95, 129.47, 78.71, 63.86, 66.31, 69.14, 84.81, 118.46, 67.52, 40.33, 87.73, 46.34, 55.88, 66.93, 85.46, 130.03, 85.77), Sim053 = c(69.54, 94.8, 158.78, 47.58, 45.09, 29.65, 69.53, 36.24, 101.68, 63.58, 54.03, 157.1, 52.78, 72.2, 45.35, 103.47, 53.52, 43.74, 60.9, 85.14), Sim054 = c(39.92, 48.19, 36.69, 49.01, 46.39, 95.15, 139.94, 109.69, 72.34, 45.89, 72.94, 64.4, 61.13, 28.13, 95.76, 133.6, 121.57, 40.21, 118.29, 33.56), Sim055 = c(80.18, 64.11, 73.13, 43.64, 72.62, 93.36, 55.58, 72.2, 44.95, 176.77, 33.08, 87.33, 50.86, 75.27, 74.68, 110.55, 34.23, 58.23, 73.04, 77.96), Sim056 = c(51.11, 48.25, 68.3, 34.38, 41.18, 45.43, 51.55, 72.79, 77.97, 170.95, 79.26, 43.51, 53.14, 38.4, 65.34, 68.69, 71.58, 109.44, 35.29, 95.03), Sim057 = c(117.02, 35.8, 49.18, 53.25, 61.22, 49.9, 78.82, 26.87, 113.83, 41.02, 78.64, 48.17, 47.2, 28.92, 69.97, 56.97, 41.39, 43.83, 148.6, 68.75), Sim058 = c(66.01, 62.38, 61.91, 100.88, 75.68, 70.96, 119.97, 40.18, 84.75, 42.18, 81.37, 74.45, 62.03, 39.8, 63.51, 35.9, 60.29, 51.93, 71.17, 113.18), Sim059 = c(50.1, 49.47, 29.68, 43.19, 35.17, 95.79, 50.49, 46.12, 41.36, 55.78, 27.66, 40.3, 47.85, 81.82, 37.56, 71, 56.49, 54.95, 49.76, 58.16 ), Sim060 = c(59.82, 36.35, 88.85, 116.35, 45.49, 133.77, 41.36, 44.67, 34.49, 78.62, 57.15, 88.35, 28.35, 60.38, 68.16, 150.2, 68.82, 68.36, 68.9, 35.27), Sim061 = c(78.89, 94.1, 46.84, 70.41, 82.07, 63.92, 74.85, 45.1, 65.33, 52.73, 66.52, 37.47, 67.55, 137.72, 82.13, 85.19, 66.18, 73.32, 67.15, 57.61), Sim062 = c(81.25, 93.78, 43.91, 34.15, 97.4, 109.88, 91.72, 62.36, 70.51, 59.99, 48.28, 62.83, 41.18, 50.3, 42.9, 51.33, 39.26, 83.69, 42.38, 129.54), Sim063 = c(92.2, 53.54, 78.81, 62.42, 83.9, 48.32, 36.29, 57.05, 46.86, 51.3, 69.92, 58.82, 41.7, 80.2, 82.66, 78.44, 113.14, 72.73, 55.48, 78.88 ), Sim064 = c(68.46, 92.47, 40.15, 49.84, 38.22, 25.36, 77.04, 80.5, 68.33, 42.91, 74.06, 74.03, 71.53, 91.14, 55.99, 41.71, 45.23, 48.98, 65.36, 65.36), Sim065 = c(52.28, 120.72, 50.94, 46.4, 59.19, 55.21, 134.89, 58.24, 54.64, 39.89, 77.4, 57.98, 48.69, 43.63, 63.83, 113.99, 39.76, 62.65, 58.85, 63.1), Sim066 = c(78.03, 66.85, 27.91, 90.69, 28.72, 71.36, 73.96, 103.19, 74.18, 43.95, 75.8, 140.66, 112.48, 59.78, 109.98, 66.22, 123.03, 72.69, 76.89, 66.23), Sim067 = c(30.57, 61.86, 81.85, 59.19, 57.64, 42.83, 39.97, 73.42, 66.35, 62.56, 77.06, 60.96, 61.36, 90.85, 61.42, 121.89, 33.37, 38.83, 39.13, 70.39), Sim068 = c(48.16, 63.75, 76.4, 17.38, 52.2, 61.95, 73.14, 82.07, 33.54, 52.51, 61.77, 43.03, 68.15, 99, 41.97, 94.21, 63.38, 72.88, 84.45, 77.36), Sim069 = c(199.92, 50.89, 82.86, 30.25, 73.31, 51.05, 85.51, 52.66, 111.93, 43.89, 114.57, 36, 46.55, 118.81, 83.79, 87.48, 76.51, 36.57, 63.2, 55.37), Sim070 = c(77.63, 69.78, 41.28, 99.35, 80.91, 50.35, 63.28, 86.09, 41.5, 77.95, 49.99, 64.87, 80.73, 44.15, 59.28, 64.36, 95.07, 40.8, 103.74, 68.12), Sim071 = c(73.13, 90.19, 39.37, 92.21, 38.72, 59.3, 59.63, 38.1, 77.38, 34.77, 74.84, 43.84, 48.66, 69.32, 78.65, 89.51, 112.98, 83.36, 79.77, 69.33), Sim072 = c(48.94, 79.94, 56.45, 71.4, 114.35, 61.25, 88.91, 40.43, 71.21, 36.4, 53.34, 31.73, 70.45, 70.68, 26.03, 77.17, 139.23, 30.64, 54.62, 45.7), Sim073 = c(90.61, 42.67, 47.8, 62.26, 61.79, 78.01, 120.58, 61.89, 66.23, 69.28, 84.8, 117.08, 70.77, 49, 65.52, 56.2, 124.19, 86.22, 104.7, 59.75 ), Sim074 = c(108.82, 74.84, 52.64, 61.65, 95.5, 100.88, 61.06, 66.21, 134.45, 67.34, 67.65, 184.28, 82.28, 63.28, 80.68, 58.1, 69.79, 114.61, 114.38, 60.15), Sim075 = c(56.4, 71.83, 52.8, 46.04, 57.72, 78.28, 37.17, 54.41, 149.06, 35.09, 70.95, 60.31, 107.83, 62.06, 36.78, 119.39, 54.17, 39.29, 52.15, 91.5), Sim076 = c(73.24, 79.73, 58.04, 75.6, 99.1, 59.95, 91.25, 55.96, 89.8, 103.72, 128.09, 56.35, 70.41, 63.03, 67.42, 33.68, 52.25, 55.44, 40.41, 43.04), Sim077 = c(62.17, 71.66, 51.93, 38.59, 104.54, 70.61, 69.26, 85.57, 56.65, 56.74, 53.78, 73.24, 87.02, 63.44, 23.16, 31.31, 73.08, 24.96, 74.46, 65.09), Sim078 = c(82.22, 44.23, 111.1, 43.37, 27.78, 59.32, 60.79, 44.29, 34.12, 127.79, 43.09, 89.62, 59.46, 54.22, 33.99, 85.2, 59.62, 38.53, 56.52, 45.58), Sim079 = c(74.24, 40.5, 50.01, 62.35, 72.25, 86.32, 64.82, 94.35, 84.82, 73.1, 34.69, 24.8, 59.56, 121.09, 73.31, 31.34, 90.42, 36.34, 69.64, 78.18), Sim080 = c(55.04, 82.85, 19.32, 89.09, 66.21, 47.31, 76.09, 75.88, 51.53, 103.09, 39.1, 61.51, 49.17, 78.87, 56.77, 36.57, 91.1, 58.45, 46.61, 72.83), Sim081 = c(64.36, 99.43, 55.1, 69.66, 54.11, 47.28, 59.61, 86.49, 81.46, 60.81, 51.63, 69.41, 75.07, 73.5, 45.67, 36.28, 62.59, 52.71, 85.94, 83.04 ), Sim082 = c(52.98, 82.61, 54.28, 53.08, 57.04, 47.4, 64.55, 72.55, 80.88, 61.19, 49.76, 36.32, 60.83, 80.69, 52.83, 72.73, 76.1, 46.38, 65.93, 71.06), Sim083 = c(69.07, 81.13, 53.04, 39.36, 28.55, 41.81, 36.99, 81.61, 109.19, 54.24, 60, 57.54, 136.52, 93.04, 58.7, 73.08, 35.66, 34.86, 45.09, 76.62), Sim084 = c(90.19, 43.42, 75.16, 75.16, 33.06, 48.17, 71.74, 29.67, 56.77, 26.87, 87.69, 81.29, 58.08, 65.15, 101.91, 87.23, 42.49, 33.56, 77.63, 54.36), Sim085 = c(63.49, 82.74, 59.87, 77.88, 40.73, 71.23, 120.13, 64.18, 87.58, 121.86, 64.96, 62.73, 38.4, 85.41, 79.58, 49.38, 49, 62.84, 90.14, 49.72), Sim086 = c(88.33, 80.44, 132.63, 107.53, 64.24, 43.19, 130.09, 107.91, 60.15, 58.14, 53.03, 90.76, 78.17, 139.56, 71.73, 82.55, 53.2, 68.94, 55, 59.18), Sim087 = c(49.11, 62.7, 48.76, 99.97, 75.04, 34.77, 60.68, 68.9, 36.76, 112.95, 34.86, 73.13, 52.06, 152.08, 104.78, 119.68, 42.02, 45.43, 63.73, 125.19), Sim088 = c(67.52, 91.09, 91.14, 66.95, 60.57, 45.83, 61, 35.04, 63.79, 111.8, 87.27, 53.01, 56.64, 60.25, 31.08, 96.81, 113.34, 37.46, 73.03, 83.45), Sim089 = c(42.77, 75.16, 114, 154.67, 56.7, 79.89, 81.79, 42.84, 109.66, 41.33, 28.78, 31.88, 118.83, 59.86, 91.98, 71.25, 32.23, 44.86, 81.37, 50.76), Sim090 = c(48.1, 80.97, 50.54, 63.82, 59.58, 57.5, 63.89, 35.23, 47.96, 72.27, 36.25, 64.75, 89.16, 70.78, 51.19, 59.98, 46.58, 42.59, 58.91, 55.28), Sim091 = c(63.06, 68.09, 130.1, 57.53, 109.23, 32.15, 67.64, 56.55, 60.23, 53.15, 120.2, 40.62, 89.09, 85.86, 58.44, 44.27, 77.34, 38.93, 50.17, 69.32), Sim092 = c(38.79, 43.18, 123.18, 59.46, 48.14, 72.46, 69.64, 45.79, 51.93, 38.79, 53.44, 46.58, 41.82, 49.96, 72.31, 123.45, 66.02, 46.77, 37.24, 41.9), Sim093 = c(79.67, 47.85, 72, 66.98, 76.16, 58.75, 52.11, 60.08, 44, 61.48, 59.37, 55.79, 85.44, 43.41, 58.68, 98.53, 96.74, 61.61, 65.88, 65.4), Sim094 = c(43.82, 36.17, 50.2, 75.13, 48.34, 35.14, 71.98, 40.37, 84.7, 76.9, 104.48, 49.85, 100.88, 105.98, 187.59, 46.83, 52.21, 43.24, 54.13, 81.76), Sim095 = c(93, 60.84, 37.51, 101.75, 53.11, 53.08, 62.82, 111.24, 30.74, 49.81, 42.1, 66.54, 71.24, 67.26, 64.89, 48.8, 63.78, 51.24, 81.58, 60.91), Sim096 = c(73.68, 51.34, 148.38, 44.37, 85.09, 24.63, 85.84, 80.44, 93.39, 196.38, 42.76, 62.17, 42.13, 56.12, 56.71, 39.55, 81.37, 40.32, 72.2, 40.77), Sim097 = c(48.89, 97.01, 29.05, 112.77, 28.27, 57.75, 85.94, 51.69, 58.61, 32.72, 35.08, 44.03, 121.13, 88.94, 69.46, 75.61, 55.79, 70.04, 47.91, 217.15), Sim098 = c(110.83, 53.7, 115.46, 50.46, 92.72, 43.66, 88.45, 63.93, 54.36, 74.44, 54.67, 56.96, 46.54, 86.65, 60.91, 61.26, 47.6, 55.04, 59.69, 49.21), Sim099 = c(31.68, 47.26, 94.13, 66.91, 122.04, 55.12, 65.5, 113.39, 84.46, 79.77, 51.33, 56.98, 72.55, 55.98, 89.94, 56.12, 57.61, 47.81, 74.62, 72.74), Sim100 = c(57.1, 46.75, 32.57, 44.22, 67.5, 64.69, 46.55, 99.27, 71.21, 90.31, 68.15, 58.36, 46.42, 44.41, 80.41, 35.38, 95.21, 52.11, 55.61, 41.38)), .Names = c("Sim001", "Sim002", "Sim003", "Sim004", "Sim005", "Sim006", "Sim007", "Sim008", "Sim009", "Sim010", "Sim011", "Sim012", "Sim013", "Sim014", "Sim015", "Sim016", "Sim017", "Sim018", "Sim019", "Sim020", "Sim021", "Sim022", "Sim023", "Sim024", "Sim025", "Sim026", "Sim027", "Sim028", "Sim029", "Sim030", "Sim031", "Sim032", "Sim033", "Sim034", "Sim035", "Sim036", "Sim037", "Sim038", "Sim039", "Sim040", "Sim041", "Sim042", "Sim043", "Sim044", "Sim045", "Sim046", "Sim047", "Sim048", "Sim049", "Sim050", "Sim051", "Sim052", "Sim053", "Sim054", "Sim055", "Sim056", "Sim057", "Sim058", "Sim059", "Sim060", "Sim061", "Sim062", "Sim063", "Sim064", "Sim065", "Sim066", "Sim067", "Sim068", "Sim069", "Sim070", "Sim071", "Sim072", "Sim073", "Sim074", "Sim075", "Sim076", "Sim077", "Sim078", "Sim079", "Sim080", "Sim081", "Sim082", "Sim083", "Sim084", "Sim085", "Sim086", "Sim087", "Sim088", "Sim089", "Sim090", "Sim091", "Sim092", "Sim093", "Sim094", "Sim095", "Sim096", "Sim097", "Sim098", "Sim099", "Sim100"), row.names = c(NA, 20L), class = "data.frame") 2) The ouput for the last column looks like: $Sim100 FUN(x = X[[100L]], type = "GEV", method = ..2) [1] "Normal Approx." 95% lower CI Estimate 95% upper CI 2-year return level 47.45112 56.12244 64.79377 5-year return level 60.89166 73.38495 85.87825 10-year return level 66.75437 85.28832 103.82226 20-year return level 68.03104 97.07476 126.11849 50-year return level 62.95423 112.88572 162.81720 100-year return level 54.12096 125.15808 196.19519 For each df in lst, I would like to get the `mean` of all variables in all columns. So, make an avearge of 95% lower CI Estimate 95% upper CI 2-year return level 47.45112 56.12244 64.79377 5-year return level 60.89166 7 3.38495 85.87825 10-year return level 66.75437 85.28832 103.82226 20-year return level 68.03104 97.07476 126.11849 50-year return level 62.95423 112.88572 162.81720 100-year return level 54.12096 125.15808 196.19519 in each df. For example, 47.45112 is the mean of 95% lower CIs for 2-year return level for all columns in df1.The final format for each dataframe in lst is as shown here with rownames, and colnames. So,if lst has 4 dfs, then lst.final should have 4 dfs with the above format. Thanks for helping. AT.
I have data for 90 climate stations. For each station, I have made 100+ simulations using a statistical model. So, in R, I have 90 dataframes, each dataframe has 100+ simulations arranged column-wise. Now, I would like to fit an extreme value distribution (EVD) to each climate station. That is, fit an EVD each to the 100+ simulations and make an average of the results. Repeat the same for all other climate stations. So far, I can apply 'fevd' function to each column in a dataframe. How can I apply this on list object? library(extRemes) out.df <- lapply(df, fevd,type="GEV",method = c("MLE"))# fit GEv to each column of dataframe #lapply(out.df,plot) # make plots for all columns rlcis<-lapply(out.df,return.level, do.ci=TRUE,method="normal",return.period=c(2,5,10,20,50,100))# calc return and CIs for all columns lst=list(df,df,df,df) df=structure(list(Sim001 = c(120.79, 59.35, 51.14, 104.85, 51.09, 138.91, 254.94, 56.44, 68.3, 51.69, 51.31, 51.08, 37.17, 38.02, 62.13, 111.48, 118.38, 45.54, 44.87, 49.59), Sim002 = c(50.25, 31.17, 67.48, 104.56, 59.82, 38.09, 50.76, 70.25, 35.8, 59.2, 47.89, 55.21, 74.38, 51.88, 124.09, 91.86, 109.28, 65.61, 69.54, 55.89), Sim003 = c(30.22, 50.07, 57.66, 57.97, 62.73, 43.84, 103.61, 53.05, 60.71, 46.57, 65.87, 33.27, 60.24, 43.63, 115.68, 37.24, 43.27, 46.38, 122.97, 86.02), Sim004 = c(38.6, 39.02, 45.74, 201.55, 110.78, 49.91, 63.5, 48.65, 94.43, 37.01, 32.61, 46.39, 120.25, 45.38, 70.26, 94.02, 67.35, 55.62, 59.3, 33.96 ), Sim005 = c(43.54, 68.42, 86.02, 78.9, 40.68, 59.97, 34.5, 48.47, 68.81, 32, 49.53, 51.23, 51.42, 61.17, 38.02, 52.96, 45.25, 39.18, 42.33, 97.15), Sim006 = c(45.96, 65.21, 94.81, 106.71, 46.95, 26.93, 39.45, 33.79, 50.36, 31.22, 128.37, 177.03, 82.07, 58.02, 32.5, 96.37, 73.77, 48.96, 143.52, 50.14), Sim007 = c(66.3, 53.99, 162.7, 100.22, 48.76, 74.06, 49.3, 62.66, 158, 82.57, 94.07, 93.01, 53.88, 160.91, 63.71, 44.93, 63.82, 56.7, 58.92, 101.52), Sim008 = c(130.62, 75.48, 126.46, 49.97, 71.69, 66.81, 89.33, 52.68, 29.19, 75.88, 89.69, 59.41, 84.16, 104.49, 65.04, 66.41, 88.5, 56.64, 62.48, 77.08), Sim009 = c(60.58, 71.85, 62.08, 57.4, 63.08, 45.38, 50.97, 59.42, 159.44, 120.94, 58.66, 54.57, 77.45, 49.63, 48.88, 91.03, 103.42, 56.9, 97.04, 69.89), Sim010 = c(48.63, 51.07, 65.13, 47.59, 94.73, 42.43, 68.77, 95.83, 42.16, 133.1, 67.2, 56.91, 138.57, 39.26, 79.75, 123.67, 64.27, 64.83, 78.88, 89.74), Sim011 = c(59.85, 53.73, 116.88, 95.06, 113.44, 87.64, 47.37, 42.42, 36.69, 39.11, 76.91, 59.85, 76.29, 118.37, 39.14, 50.76, 98.06, 40.71, 53.03, 42.93), Sim012 = c(128.35, 60.21, 60.19, 51.69, 51.47, 35.44, 101.72, 82.83, 50.72, 68.66, 80.84, 59.98, 79.84, 35.52, 128.69, 53.35, 84.77, 18.38, 28.98, 48), Sim013 = c(52.88, 117.11, 103.3, 103.59, 119.06, 62.66, 65.64, 75.91, 81.78, 80.31, 22.83, 79.22, 51.33, 79.63, 86.26, 54.44, 42.86, 63.95, 166.87, 58.48), Sim014 = c(50.28, 123.9, 35.87, 133.52, 94.28, 62.35, 58.54, 42.08, 67.7, 101.44, 34.68, 45.98, 60.99, 60.06, 79.76, 61.93, 59.4, 42.02, 56.45, 81.41 ), Sim015 = c(50.32, 39.01, 100.3, 105.38, 55.49, 36.36, 56.49, 107.52, 38.7, 73.09, 98.22, 44.19, 50.17, 56.69, 44.82, 44.09, 57.57, 52.55, 90.37, 78.62), Sim016 = c(35.2, 62.77, 35.25, 52.05, 93.51, 65.84, 43.85, 54.52, 39.17, 62.02, 47.6, 34.42, 190.57, 38.46, 94.9, 73.34, 78.5, 52.84, 103.7, 51.48 ), Sim017 = c(69.03, 58.19, 130.37, 80.04, 52.96, 65.14, 65.08, 45.95, 65.35, 41.95, 78.67, 78.41, 56.51, 63.52, 52.93, 52.32, 70.14, 81.59, 70.99, 105.02), Sim018 = c(55.98, 44.37, 59.07, 36.65, 44.16, 26.62, 125.38, 75.54, 75.46, 25.62, 22.95, 65.74, 72.86, 53.5, 32.05, 58.98, 70.87, 30.95, 78.25, 54.75), Sim019 = c(147.82, 37.48, 161.91, 46.28, 95.4, 74.79, 53.51, 58.73, 50.96, 32.03, 50.08, 60.03, 76.75, 45.31, 58.29, 52.91, 42.84, 74.52, 83.19, 43.8), Sim020 = c(59.33, 218.52, 64.55, 73.07, 59.9, 39.09, 129.88, 61.53, 56.7, 38.55, 62.2, 29.25, 52.74, 57.86, 46.04, 80.03, 44.61, 88.52, 45.36, 93.97 ), Sim021 = c(93.44, 41.32, 67.08, 99.15, 89.43, 31.64, 38.59, 65.08, 58.9, 52.7, 47.39, 47.91, 90.93, 54.57, 51.26, 44.59, 33.52, 38.69, 44.92, 50.46), Sim022 = c(43.37, 43.47, 63.15, 77.19, 117.13, 77.32, 65.36, 67.49, 49.18, 87.66, 70.09, 110.66, 70.85, 46.71, 55.36, 45.53, 30.55, 51.7, 46.08, 65.91 ), Sim023 = c(65.76, 42.75, 50.2, 58.23, 69.27, 75.63, 46.72, 72.47, 62.53, 50.87, 58.8, 63.61, 39.99, 91.36, 66.07, 100.32, 55.34, 32.59, 59.8, 43.96), Sim024 = c(174.2, 70.17, 47.86, 71.24, 91.39, 40.5, 28.66, 64.57, 33.02, 46.27, 68.56, 56.68, 97.28, 46.24, 65.76, 72.53, 60.26, 128.26, 85.63, 107.29), Sim025 = c(84.66, 38.95, 43.63, 41.33, 108.67, 62.94, 64.73, 57.26, 42.11, 100.24, 28, 35.95, 175.8, 61.64, 81.42, 67.55, 68.12, 35.1, 46.63, 105.43), Sim026 = c(64.17, 55.25, 59.21, 49.21, 104.75, 129.05, 76.05, 69.88, 110.19, 40.71, 103.17, 74.32, 64.18, 55.66, 105.93, 36.25, 81.08, 75.96, 81.67, 99.22), Sim027 = c(55.07, 53.32, 71.68, 37.51, 96.35, 42.25, 41.22, 41.09, 67.46, 69.64, 54.6, 37.63, 106.3, 121.53, 67, 24.6, 64.82, 64.82, 68.65, 98.26), Sim028 = c(56.44, 27.16, 45.64, 59.74, 55.09, 28.91, 94.48, 42.9, 91.21, 79.34, 41.06, 42.36, 57.21, 38.13, 46.28, 75.48, 83.1, 72.94, 98.49, 66.73 ), Sim029 = c(49.77, 49.29, 54.16, 83.52, 48.06, 61.06, 26.69, 68.11, 51.43, 56.84, 35.05, 87.57, 160.17, 48.4, 95.22, 74.41, 69.18, 43.84, 65.14, 65.05), Sim030 = c(63.45, 62.12, 81.56, 66.5, 53.21, 49.33, 44.95, 50.49, 81.7, 59.45, 46.68, 100.52, 128.92, 75.38, 74.2, 46.92, 96.02, 42.79, 73.97, 35.67), Sim031 = c(42.32, 44.08, 63.43, 74.42, 78.09, 59.41, 54.34, 103.51, 74.34, 42.34, 32.86, 76.19, 56.32, 79, 79.11, 37.75, 46.15, 43.67, 78.34, 115.33), Sim032 = c(60.6, 46.4, 179.78, 102.86, 57.86, 34.29, 68.26, 56.88, 103.82, 97.29, 56.46, 104.64, 58.03, 70.71, 53.61, 111.52, 77.73, 49.03, 48.64, 69.16), Sim033 = c(35.23, 42.14, 64.93, 74.66, 183.2, 26.87, 59.4, 73.74, 63.13, 37.65, 64.59, 45, 75.46, 78.81, 66.73, 56.63, 50.68, 56.87, 69.41, 86.37), Sim034 = c(51.52, 108.22, 47.16, 41.77, 62.01, 85.64, 66.62, 58.47, 167.55, 34.71, 73.55, 43.42, 122.87, 53.81, 48.08, 59.5, 83.6, 46.33, 55.82, 76.99), Sim035 = c(37.25, 41.93, 74.69, 61.38, 78.29, 70.13, 56.44, 36.66, 94.21, 97.32, 46, 45.78, 32.85, 57.05, 61.26, 69.1, 43.26, 41.41, 69.67, 147.57), Sim036 = c(67.96, 59.22, 65.29, 64.49, 41.23, 39.53, 46.21, 32.87, 88.47, 59.53, 44.28, 73.41, 38.3, 72.1, 77.33, 43.23, 99.6, 49.46, 63.7, 54.96 ), Sim037 = c(73.31, 60.02, 46.72, 69.75, 39.97, 42.39, 69, 70.86, 86.68, 79.96, 46.88, 43.91, 70.03, 53.46, 59.72, 112.63, 44.71, 91.34, 80.78, 58.28), Sim038 = c(66.82, 67.99, 72.85, 108.32, 45.14, 54.1, 68.67, 68.01, 51.8, 43.09, 43.94, 46.68, 61.19, 75.64, 74.25, 43.64, 114.62, 43.71, 43.1, 66.72), Sim039 = c(41.57, 39.89, 172.91, 45.93, 146.08, 64.04, 51.16, 60.84, 63.01, 59.85, 43.72, 118.3, 57.85, 64.73, 141.46, 48.84, 109.66, 53.85, 49.28, 33.75), Sim040 = c(41.66, 203.26, 29.55, 64.55, 43.06, 85.98, 89.09, 80.92, 83.08, 40.77, 47.7, 120.21, 88.37, 71.86, 86.6, 122.06, 59.61, 73.06, 67.51, 165.09), Sim041 = c(43.02, 33.99, 32.19, 60.84, 34.49, 31.81, 46.81, 56.2, 74.42, 59.62, 48.4, 53.33, 78.04, 100.36, 92.8, 147.88, 89.32, 38.73, 76.25, 93.83), Sim042 = c(64.27, 49.35, 99.48, 86.88, 24.19, 54.45, 111.73, 72.6, 57.73, 75.14, 42.85, 96.38, 55.17, 82.13, 72.9, 68.29, 76.44, 41.64, 83.17, 89.69 ), Sim043 = c(92.51, 127.4, 68.69, 45.07, 65.78, 40.81, 35.22, 41.47, 50.94, 73.3, 55.48, 91.55, 60.15, 39.31, 110.71, 73.27, 92.3, 64.83, 74.21, 57.68), Sim044 = c(46.86, 68.48, 51.29, 83.66, 87.2, 79.22, 62.5, 25.17, 44.04, 55.36, 69.23, 23.23, 43.22, 43.38, 34.28, 96.67, 42.1, 52, 95.03, 43.73), Sim045 = c(111.78, 63.81, 126.77, 49.3, 60.11, 42.84, 47, 22.98, 48.41, 144.18, 42.21, 85.14, 105.72, 86.97, 55.17, 73.22, 122.86, 60.04, 31.13, 95.21), Sim046 = c(43.29, 40.17, 53.99, 29.43, 87.25, 58.74, 81.31, 74.3, 48.47, 91.82, 60.84, 74.5, 94.22, 43.77, 55.42, 71.17, 54.49, 76.96, 58.04, 57.95), Sim047 = c(51.58, 50.48, 51.44, 38.82, 49.5, 59.16, 46.11, 43.95, 109.03, 57.92, 62.12, 68.25, 42.59, 82.52, 63.36, 84.1, 77.16, 183.01, 80.42, 57.06), Sim048 = c(39.95, 57.88, 33.13, 57.07, 123.89, 39.91, 94.86, 80.16, 104.46, 86.94, 87.65, 82.74, 69.6, 79.83, 32.9, 34.05, 45.11, 83.16, 78.13, 56.18), Sim049 = c(15.68, 65.54, 71.53, 148.3, 79.93, 49.64, 82.59, 34, 77.56, 92.19, 158.28, 82.13, 46.34, 93.22, 93.89, 59.37, 47.72, 40.11, 128.32, 67.29), Sim050 = c(37.63, 43.41, 143.61, 157.48, 39.44, 73.62, 75.41, 86.69, 58.29, 66.7, 45.95, 34.3, 61.8, 78.35, 58.18, 60.04, 84.08, 76.19, 70.58, 73.57), Sim051 = c(68.28, 50.97, 62.66, 45.23, 92.23, 93.46, 53.17, 108.31, 45.67, 121.95, 46.52, 66.13, 75.3, 42.31, 85.94, 77.72, 111.41, 57.23, 203.79, 68.42), Sim052 = c(86.42, 75.88, 57.99, 72.95, 129.47, 78.71, 63.86, 66.31, 69.14, 84.81, 118.46, 67.52, 40.33, 87.73, 46.34, 55.88, 66.93, 85.46, 130.03, 85.77), Sim053 = c(69.54, 94.8, 158.78, 47.58, 45.09, 29.65, 69.53, 36.24, 101.68, 63.58, 54.03, 157.1, 52.78, 72.2, 45.35, 103.47, 53.52, 43.74, 60.9, 85.14), Sim054 = c(39.92, 48.19, 36.69, 49.01, 46.39, 95.15, 139.94, 109.69, 72.34, 45.89, 72.94, 64.4, 61.13, 28.13, 95.76, 133.6, 121.57, 40.21, 118.29, 33.56), Sim055 = c(80.18, 64.11, 73.13, 43.64, 72.62, 93.36, 55.58, 72.2, 44.95, 176.77, 33.08, 87.33, 50.86, 75.27, 74.68, 110.55, 34.23, 58.23, 73.04, 77.96), Sim056 = c(51.11, 48.25, 68.3, 34.38, 41.18, 45.43, 51.55, 72.79, 77.97, 170.95, 79.26, 43.51, 53.14, 38.4, 65.34, 68.69, 71.58, 109.44, 35.29, 95.03), Sim057 = c(117.02, 35.8, 49.18, 53.25, 61.22, 49.9, 78.82, 26.87, 113.83, 41.02, 78.64, 48.17, 47.2, 28.92, 69.97, 56.97, 41.39, 43.83, 148.6, 68.75), Sim058 = c(66.01, 62.38, 61.91, 100.88, 75.68, 70.96, 119.97, 40.18, 84.75, 42.18, 81.37, 74.45, 62.03, 39.8, 63.51, 35.9, 60.29, 51.93, 71.17, 113.18), Sim059 = c(50.1, 49.47, 29.68, 43.19, 35.17, 95.79, 50.49, 46.12, 41.36, 55.78, 27.66, 40.3, 47.85, 81.82, 37.56, 71, 56.49, 54.95, 49.76, 58.16 ), Sim060 = c(59.82, 36.35, 88.85, 116.35, 45.49, 133.77, 41.36, 44.67, 34.49, 78.62, 57.15, 88.35, 28.35, 60.38, 68.16, 150.2, 68.82, 68.36, 68.9, 35.27), Sim061 = c(78.89, 94.1, 46.84, 70.41, 82.07, 63.92, 74.85, 45.1, 65.33, 52.73, 66.52, 37.47, 67.55, 137.72, 82.13, 85.19, 66.18, 73.32, 67.15, 57.61), Sim062 = c(81.25, 93.78, 43.91, 34.15, 97.4, 109.88, 91.72, 62.36, 70.51, 59.99, 48.28, 62.83, 41.18, 50.3, 42.9, 51.33, 39.26, 83.69, 42.38, 129.54), Sim063 = c(92.2, 53.54, 78.81, 62.42, 83.9, 48.32, 36.29, 57.05, 46.86, 51.3, 69.92, 58.82, 41.7, 80.2, 82.66, 78.44, 113.14, 72.73, 55.48, 78.88 ), Sim064 = c(68.46, 92.47, 40.15, 49.84, 38.22, 25.36, 77.04, 80.5, 68.33, 42.91, 74.06, 74.03, 71.53, 91.14, 55.99, 41.71, 45.23, 48.98, 65.36, 65.36), Sim065 = c(52.28, 120.72, 50.94, 46.4, 59.19, 55.21, 134.89, 58.24, 54.64, 39.89, 77.4, 57.98, 48.69, 43.63, 63.83, 113.99, 39.76, 62.65, 58.85, 63.1), Sim066 = c(78.03, 66.85, 27.91, 90.69, 28.72, 71.36, 73.96, 103.19, 74.18, 43.95, 75.8, 140.66, 112.48, 59.78, 109.98, 66.22, 123.03, 72.69, 76.89, 66.23), Sim067 = c(30.57, 61.86, 81.85, 59.19, 57.64, 42.83, 39.97, 73.42, 66.35, 62.56, 77.06, 60.96, 61.36, 90.85, 61.42, 121.89, 33.37, 38.83, 39.13, 70.39), Sim068 = c(48.16, 63.75, 76.4, 17.38, 52.2, 61.95, 73.14, 82.07, 33.54, 52.51, 61.77, 43.03, 68.15, 99, 41.97, 94.21, 63.38, 72.88, 84.45, 77.36), Sim069 = c(199.92, 50.89, 82.86, 30.25, 73.31, 51.05, 85.51, 52.66, 111.93, 43.89, 114.57, 36, 46.55, 118.81, 83.79, 87.48, 76.51, 36.57, 63.2, 55.37), Sim070 = c(77.63, 69.78, 41.28, 99.35, 80.91, 50.35, 63.28, 86.09, 41.5, 77.95, 49.99, 64.87, 80.73, 44.15, 59.28, 64.36, 95.07, 40.8, 103.74, 68.12), Sim071 = c(73.13, 90.19, 39.37, 92.21, 38.72, 59.3, 59.63, 38.1, 77.38, 34.77, 74.84, 43.84, 48.66, 69.32, 78.65, 89.51, 112.98, 83.36, 79.77, 69.33), Sim072 = c(48.94, 79.94, 56.45, 71.4, 114.35, 61.25, 88.91, 40.43, 71.21, 36.4, 53.34, 31.73, 70.45, 70.68, 26.03, 77.17, 139.23, 30.64, 54.62, 45.7), Sim073 = c(90.61, 42.67, 47.8, 62.26, 61.79, 78.01, 120.58, 61.89, 66.23, 69.28, 84.8, 117.08, 70.77, 49, 65.52, 56.2, 124.19, 86.22, 104.7, 59.75 ), Sim074 = c(108.82, 74.84, 52.64, 61.65, 95.5, 100.88, 61.06, 66.21, 134.45, 67.34, 67.65, 184.28, 82.28, 63.28, 80.68, 58.1, 69.79, 114.61, 114.38, 60.15), Sim075 = c(56.4, 71.83, 52.8, 46.04, 57.72, 78.28, 37.17, 54.41, 149.06, 35.09, 70.95, 60.31, 107.83, 62.06, 36.78, 119.39, 54.17, 39.29, 52.15, 91.5), Sim076 = c(73.24, 79.73, 58.04, 75.6, 99.1, 59.95, 91.25, 55.96, 89.8, 103.72, 128.09, 56.35, 70.41, 63.03, 67.42, 33.68, 52.25, 55.44, 40.41, 43.04), Sim077 = c(62.17, 71.66, 51.93, 38.59, 104.54, 70.61, 69.26, 85.57, 56.65, 56.74, 53.78, 73.24, 87.02, 63.44, 23.16, 31.31, 73.08, 24.96, 74.46, 65.09), Sim078 = c(82.22, 44.23, 111.1, 43.37, 27.78, 59.32, 60.79, 44.29, 34.12, 127.79, 43.09, 89.62, 59.46, 54.22, 33.99, 85.2, 59.62, 38.53, 56.52, 45.58), Sim079 = c(74.24, 40.5, 50.01, 62.35, 72.25, 86.32, 64.82, 94.35, 84.82, 73.1, 34.69, 24.8, 59.56, 121.09, 73.31, 31.34, 90.42, 36.34, 69.64, 78.18), Sim080 = c(55.04, 82.85, 19.32, 89.09, 66.21, 47.31, 76.09, 75.88, 51.53, 103.09, 39.1, 61.51, 49.17, 78.87, 56.77, 36.57, 91.1, 58.45, 46.61, 72.83), Sim081 = c(64.36, 99.43, 55.1, 69.66, 54.11, 47.28, 59.61, 86.49, 81.46, 60.81, 51.63, 69.41, 75.07, 73.5, 45.67, 36.28, 62.59, 52.71, 85.94, 83.04 ), Sim082 = c(52.98, 82.61, 54.28, 53.08, 57.04, 47.4, 64.55, 72.55, 80.88, 61.19, 49.76, 36.32, 60.83, 80.69, 52.83, 72.73, 76.1, 46.38, 65.93, 71.06), Sim083 = c(69.07, 81.13, 53.04, 39.36, 28.55, 41.81, 36.99, 81.61, 109.19, 54.24, 60, 57.54, 136.52, 93.04, 58.7, 73.08, 35.66, 34.86, 45.09, 76.62), Sim084 = c(90.19, 43.42, 75.16, 75.16, 33.06, 48.17, 71.74, 29.67, 56.77, 26.87, 87.69, 81.29, 58.08, 65.15, 101.91, 87.23, 42.49, 33.56, 77.63, 54.36), Sim085 = c(63.49, 82.74, 59.87, 77.88, 40.73, 71.23, 120.13, 64.18, 87.58, 121.86, 64.96, 62.73, 38.4, 85.41, 79.58, 49.38, 49, 62.84, 90.14, 49.72), Sim086 = c(88.33, 80.44, 132.63, 107.53, 64.24, 43.19, 130.09, 107.91, 60.15, 58.14, 53.03, 90.76, 78.17, 139.56, 71.73, 82.55, 53.2, 68.94, 55, 59.18), Sim087 = c(49.11, 62.7, 48.76, 99.97, 75.04, 34.77, 60.68, 68.9, 36.76, 112.95, 34.86, 73.13, 52.06, 152.08, 104.78, 119.68, 42.02, 45.43, 63.73, 125.19), Sim088 = c(67.52, 91.09, 91.14, 66.95, 60.57, 45.83, 61, 35.04, 63.79, 111.8, 87.27, 53.01, 56.64, 60.25, 31.08, 96.81, 113.34, 37.46, 73.03, 83.45), Sim089 = c(42.77, 75.16, 114, 154.67, 56.7, 79.89, 81.79, 42.84, 109.66, 41.33, 28.78, 31.88, 118.83, 59.86, 91.98, 71.25, 32.23, 44.86, 81.37, 50.76), Sim090 = c(48.1, 80.97, 50.54, 63.82, 59.58, 57.5, 63.89, 35.23, 47.96, 72.27, 36.25, 64.75, 89.16, 70.78, 51.19, 59.98, 46.58, 42.59, 58.91, 55.28), Sim091 = c(63.06, 68.09, 130.1, 57.53, 109.23, 32.15, 67.64, 56.55, 60.23, 53.15, 120.2, 40.62, 89.09, 85.86, 58.44, 44.27, 77.34, 38.93, 50.17, 69.32), Sim092 = c(38.79, 43.18, 123.18, 59.46, 48.14, 72.46, 69.64, 45.79, 51.93, 38.79, 53.44, 46.58, 41.82, 49.96, 72.31, 123.45, 66.02, 46.77, 37.24, 41.9), Sim093 = c(79.67, 47.85, 72, 66.98, 76.16, 58.75, 52.11, 60.08, 44, 61.48, 59.37, 55.79, 85.44, 43.41, 58.68, 98.53, 96.74, 61.61, 65.88, 65.4), Sim094 = c(43.82, 36.17, 50.2, 75.13, 48.34, 35.14, 71.98, 40.37, 84.7, 76.9, 104.48, 49.85, 100.88, 105.98, 187.59, 46.83, 52.21, 43.24, 54.13, 81.76), Sim095 = c(93, 60.84, 37.51, 101.75, 53.11, 53.08, 62.82, 111.24, 30.74, 49.81, 42.1, 66.54, 71.24, 67.26, 64.89, 48.8, 63.78, 51.24, 81.58, 60.91), Sim096 = c(73.68, 51.34, 148.38, 44.37, 85.09, 24.63, 85.84, 80.44, 93.39, 196.38, 42.76, 62.17, 42.13, 56.12, 56.71, 39.55, 81.37, 40.32, 72.2, 40.77), Sim097 = c(48.89, 97.01, 29.05, 112.77, 28.27, 57.75, 85.94, 51.69, 58.61, 32.72, 35.08, 44.03, 121.13, 88.94, 69.46, 75.61, 55.79, 70.04, 47.91, 217.15), Sim098 = c(110.83, 53.7, 115.46, 50.46, 92.72, 43.66, 88.45, 63.93, 54.36, 74.44, 54.67, 56.96, 46.54, 86.65, 60.91, 61.26, 47.6, 55.04, 59.69, 49.21), Sim099 = c(31.68, 47.26, 94.13, 66.91, 122.04, 55.12, 65.5, 113.39, 84.46, 79.77, 51.33, 56.98, 72.55, 55.98, 89.94, 56.12, 57.61, 47.81, 74.62, 72.74), Sim100 = c(57.1, 46.75, 32.57, 44.22, 67.5, 64.69, 46.55, 99.27, 71.21, 90.31, 68.15, 58.36, 46.42, 44.41, 80.41, 35.38, 95.21, 52.11, 55.61, 41.38)), .Names = c("Sim001", "Sim002", "Sim003", "Sim004", "Sim005", "Sim006", "Sim007", "Sim008", "Sim009", "Sim010", "Sim011", "Sim012", "Sim013", "Sim014", "Sim015", "Sim016", "Sim017", "Sim018", "Sim019", "Sim020", "Sim021", "Sim022", "Sim023", "Sim024", "Sim025", "Sim026", "Sim027", "Sim028", "Sim029", "Sim030", "Sim031", "Sim032", "Sim033", "Sim034", "Sim035", "Sim036", "Sim037", "Sim038", "Sim039", "Sim040", "Sim041", "Sim042", "Sim043", "Sim044", "Sim045", "Sim046", "Sim047", "Sim048", "Sim049", "Sim050", "Sim051", "Sim052", "Sim053", "Sim054", "Sim055", "Sim056", "Sim057", "Sim058", "Sim059", "Sim060", "Sim061", "Sim062", "Sim063", "Sim064", "Sim065", "Sim066", "Sim067", "Sim068", "Sim069", "Sim070", "Sim071", "Sim072", "Sim073", "Sim074", "Sim075", "Sim076", "Sim077", "Sim078", "Sim079", "Sim080", "Sim081", "Sim082", "Sim083", "Sim084", "Sim085", "Sim086", "Sim087", "Sim088", "Sim089", "Sim090", "Sim091", "Sim092", "Sim093", "Sim094", "Sim095", "Sim096", "Sim097", "Sim098", "Sim099", "Sim100"), row.names = c(NA, 20L), class = "data.frame") 2) The ouput for the last column looks like: $Sim100 FUN(x = X[[100L]], type = "GEV", method = ..2) [1] "Normal Approx." 95% lower CI Estimate 95% upper CI 2-year return level 47.45112 56.12244 64.79377 5-year return level 60.89166 73.38495 85.87825 10-year return level 66.75437 85.28832 103.82226 20-year return level 68.03104 97.07476 126.11849 50-year return level 62.95423 112.88572 162.81720 100-year return level 54.12096 125.15808 196.19519 For each df in lst, I would like to make an avearge of 95% lower CI Estimate 95% upper CI 2-year return level 47.45112 56.12244 64.79377 5-year return level 60.89166 7 3.38495 85.87825 10-year return level 66.75437 85.28832 103.82226 20-year return level 68.03104 97.07476 126.11849 50-year return level 62.95423 112.88572 162.81720 100-year return level 54.12096 125.15808 196.19519 in each df. For example, 47.45112 is the mean of 95% lower CIs for 2-year return level for all columns in df1.The final format for each dataframe in lst is as shown here with rownames, and colnames. So,if lst has 4 dfs, then lst.final should have 4 dfs with the above format. Please help. AT.