Click or drag to resize
FrameExtensionsSaveCsvR, C Method (FrameR, C, TextWriter, Boolean, IEnumerableString, Char, CultureInfo)
Save data frame to a CSV file or to a `Stream`. When calling the operation, you can specify whether you want to save the row keys or not (and headers for the keys) and you can also specify the separator (use `\t` for writing TSV files). When specifying file name ending with `.tsv`, the `\t` separator is used automatically. ## Parameters - `writer` - Specifies the text writer to which the CSV data should be written - `includeRowKeys` - When set to `true`, the row key is also written to the output file - `keyNames` - Can be used to specify the CSV headers for row key (or keys, for multi-level index) - `separator` - Specify the column separator in the file (the default is `\t` for TSV files and `,` for CSV files) - `culture` - Specify the `CultureInfo` object used for formatting numerical data [category:Input and output]

Namespace:  Deedle
Assembly:  Deedle (in Deedle.dll) Version: 1.2
Syntax
C#
public static void SaveCsv<R, C>(
	this Frame<R, C> frame,
	TextWriter writer,
	[OptionalAttribute] bool includeRowKeys,
	[OptionalAttribute] IEnumerable<string> keyNames,
	[OptionalAttribute] char separator,
	[OptionalAttribute] CultureInfo culture
)

Parameters

frame
Type: DeedleFrameR, C

[Missing <param name="frame"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

writer
Type: System.IOTextWriter

[Missing <param name="writer"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

includeRowKeys (Optional)
Type: SystemBoolean

[Missing <param name="includeRowKeys"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

keyNames (Optional)
Type: System.Collections.GenericIEnumerableString

[Missing <param name="keyNames"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

separator (Optional)
Type: SystemChar

[Missing <param name="separator"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

culture (Optional)
Type: System.GlobalizationCultureInfo

[Missing <param name="culture"/> documentation for "M:Deedle.FrameExtensions.SaveCsv``2(Deedle.Frame{``0,``1},System.IO.TextWriter,System.Boolean,System.Collections.Generic.IEnumerable{System.String},System.Char,System.Globalization.CultureInfo)"]

Type Parameters

R
C

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type FrameR, C. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also