mirror of
				https://github.com/qurator-spk/modstool.git
				synced 2025-11-04 03:14:14 +01:00 
			
		
		
		
	🚧 ALTO: Calculate more descriptive statistics for String@WC
This commit is contained in:
		
							parent
							
								
									aa4e8e290d
								
							
						
					
					
						commit
						8285bdb423
					
				
					 1 changed files with 6 additions and 1 deletions
				
			
		| 
						 | 
					@ -221,7 +221,12 @@ class TagGroup:
 | 
				
			||||||
        values = np.array([float(v) for v in values])
 | 
					        values = np.array([float(v) for v in values])
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        statistics = {}
 | 
					        statistics = {}
 | 
				
			||||||
 | 
					        if values.size > 0:
 | 
				
			||||||
            statistics[f'{xpath_expr}-mean'] = np.mean(values)
 | 
					            statistics[f'{xpath_expr}-mean'] = np.mean(values)
 | 
				
			||||||
 | 
					            statistics[f'{xpath_expr}-median'] = np.median(values)
 | 
				
			||||||
 | 
					            statistics[f'{xpath_expr}-std'] = np.std(values)
 | 
				
			||||||
 | 
					            statistics[f'{xpath_expr}-min'] = np.min(values)
 | 
				
			||||||
 | 
					            statistics[f'{xpath_expr}-max'] = np.max(values)
 | 
				
			||||||
        return statistics
 | 
					        return statistics
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue