Skip to content

system.dataset.join #51

@JosephTLockwood

Description

@JosephTLockwood

Function to join to datasets.

Currently, I only use the left joins. I am assuming this would most likely be able to do left, right, and inner joins.

def dataSetToDict(dataSet, headers = None):
	finalDict = {}
	if headers is None:
		headers = dataSet.getColumnNames().toArray()	
	
	for col in range(dataSet.getColumnCount()):	
		tempArray = []
		for row in range(dataSet.getRowCount()):
			value = dataSet.getValueAt(row, col)
			if value != 'None' and value is not None:
				#print(value)
				tempArray.append(value)
		finalDict[headers[col]] = tempArray
	
	return finalDict

Will work on this in free time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions