Java में डेटा इम्पोर्ट करना
Anthony Markham
VP Quant Developer
Table employees = Table.create("Employees");
StringColumn nameCol = StringColumn.create("Name");
Row firstRow = employees.row(0);
String tableName = employees.name();
employees
// पंक्ति और कॉलम की गिनती
int rowCount = employees.rowCount();
int columnCount = employees.columnCount();
1000
5
StringColumn - टेक्स्ट डेटाIntColumn, DoubleColumn - संख्यात्मक मानBooleanColumn - True/False मानDateColumn - कैलेंडर तिथियाँ (2024-03-05)DateTimeColumn - डेटटाइम (2024-03-05T14:32)// DoubleColumn पर .mean() का उपयोग
DoubleColumn salary = employees.column("Salary");
double averageSalary = salary.mean();
// एक विशिष्ट कॉलम लें StringColumn names = employees.stringColumn("Name");// एक जनरल कॉलम लें names = employees.column("Name");// कॉलम से एक मान लें String firstPerson = names.get(0);// पूरी पंक्ति लें Row firstRow = employees.row(0);// पंक्ति से एक मान लें double salary = firstRow.getDouble("Salary");
.isGreaterThan(), .isLessThan().isEqualTo().isAfter()$$
// पंक्तियों का एक चयन बनाएँ
Selection highEarners = employees.doubleColumn("Salary")
.isGreaterThan(70000);
// पंक्तियों का एक चयन बनाएँ Selection highEarners = employees.doubleColumn("Salary") .isGreaterThan(70000);// चयन लागू करें और फ़िल्टर की हुई टेबल पाएँ Table highPaidEmployees = employees.where(highEarners);
$$
$$
.where() एक नई टेबल लौटाता है.and() और .or() से जोड़ेंSelection recentHires = employees.dateColumn("HireDate") .isAfter(LocalDate.of(2020, 1, 1));Selection highPaidRecent = highEarners.and(recentHires);
Java में डेटा इम्पोर्ट करना