• Recent
    • Tags
    • Popular
    • Register
    • Login
    1. Home
    2. Jerrod Tanner
    3. Posts

    Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.

    Radix IoT Website Mango 3 Documentation Website Mango 4 Documentation Website Mango 5 Documentation Website
    J
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 3
    • Best 0
    • Controversial 0
    • Groups 0

    Posts made by Jerrod Tanner

    • RE: CSV as data points

      @mattfox thanks so much for the help, I made a silly mistake but I am glad it made me more familiar with Mango. I ended up crafting quite the nice CSV importer with some bells and whistles.

      posted in User help
      J
      Jerrod Tanner
    • RE: CSV as data points

      0_1593712964341_4663f5f5-5153-4a33-9864-e5aa6c5d967f-image.png

      public class MultiColumnCsvImporter extends AbstractCSVDataSource {
      	
      	private Map<Integer, String> headerMap = new HashMap<Integer, String>();
      	
      	
      	@Override
      	public void importRow(String[] row, int rowNum) {
      		//Strip out the header row, it does not contain our data
      		if(rowNum == 0){
      			for(int k = 0; k < row.length; ++k) {
      				this.headerMap.put(k, row[k]);
      			}
      		}else{
      			
      			//Column 0 is the time
      			Integer Id = Integer.parseInt(row[0]);
      			
      			//Empty additional parameters
      			Map<String, String> extraParams = new HashMap<String,String>();
      			
      			//For each additional column we will create an Import Point
      			for(int i=1; i<row.length; i++){
      				String identifier = headerMap.get(i); //Get the identifier from our header map
      				double value = Double.parseDouble(row*); //Create the value
      				NumericImportPoint point = new NumericImportPoint(identifier, value, Id, extraParams);
      				this.parsedPoints.add(point);
      			}
      		}
      	}
      }
      

      0_1593713145809_d3c57461-9762-4b63-8144-943d22f41b85-image.png

      So here you can see data points for only the last row.

      posted in User help
      J
      Jerrod Tanner
    • CSV as data points

      Hi, I am very new to Mango and have been working on taking CSV files and making their columns into data points. I used the default multi column CSV importer which works fine, I get my columns as data points inside my CSV data source in Mango. My issue is that it will only create points for the last row. How can I get all or even a select few rows?

      posted in User help
      J
      Jerrod Tanner