-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This adds a Logical Type Time to Series. Arrow time32/time64 will be converted to arrow time64(nanosecond) when converted to polars.
- Loading branch information
Showing
38 changed files
with
1,019 additions
and
587 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
use super::*; | ||
use crate::prelude::*; | ||
|
||
pub type TimeChunked = Logical<TimeType, Int64Type>; | ||
|
||
impl From<Int64Chunked> for TimeChunked { | ||
fn from(ca: Int64Chunked) -> Self { | ||
TimeChunked::new(ca) | ||
} | ||
} | ||
|
||
impl Int64Chunked { | ||
pub fn into_time(self) -> TimeChunked { | ||
TimeChunked::new(self) | ||
} | ||
} | ||
|
||
impl LogicalType for TimeChunked { | ||
fn dtype(&self) -> &'static DataType { | ||
&DataType::Time | ||
} | ||
} |
Oops, something went wrong.