Giter VIP home page Giter VIP logo

iocsv's Introduction

ioCSV v 0.67 (release)

Can Koluman, PhD Candidate, City, University of London, Department of Computer Science

A simple CSV (comma separated values) io Library in Scala https://github.com/cankoluman/ioCSV

Also available at https://search.maven.org/artifact/com.cankoluman/ioCSV For Maven, Groovy DSL, Kotlin DSL, Scala SBT, Ivy, and others.

News

Version 0.67 uses Scala 3.2.0. Also, the project now is IDE independent. Maven is sufficient to run it, even from a bash shell.

Introduction

This is a very lightweight csv (comma separated values) exporter implementation. The to be exported data is wrapped in a Frame[A] structure, which is passed to the csvRead(source: String, gZip: Boolean): Frame[A] or csvWrite(source: Frame[A], target: String, gZip: Boolean, append: Boolean): Unit methods. At the moment, we only have read / write for [A] = Vector[Vector[B]] via the VectorToCsv class. More info in the comments. The implementation will grow slightly over time.

Customizables

  • Headers: true / false, Frame.header: Option[Vector[String]]
  • Separator: Char
  • Encoding: Codec, e.g. Codec(StandardCharsets.UTF_8)
  • Gzip: true / false (when reading from / writing to a file)
  • Append: true / false (when writing to a file)

Dependencies

  • Scala
  • Scala Library
  • Scalatest 3
  • Scalatestplus:mockito 4-5_3
  • Mockito Core

TO DO

  • Add csv io for transposed Vector[Vector[A]]
  • Add csv io for ListMap[String, Vector[A]]
  • Add csv io for DenseMatrix[A] (Breeze)

Copyright Notices

© 2022 Copyright, Can Koluman. Apache 2.0 Licence for authored components.

© Copyright 2022 Can Koluman

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at_

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License._

For open sourced components / libraries, respective origin licenses apply.

iocsv's People

Contributors

cankoluman avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.