question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Integer Default Parameters for Plotting Methods

See original GitHub issue

The goal is to allow for this syntax;

emb.transform(Pca(2)).plot(x_axis=0, y_axis=1)

The reasoning is currently you have to write;

emb.transform(Pca(2)).plot(x_axis="pca_0", y_axis="pca_1")

This get’s annoying when you want to replace the Pca with Umap.

emb.transform(Umap(2)).plot(x_axis="umap_0", y_axis="umap_1")

What’s even nicer is that with proper default arguments in the future you can just run;

emb.transform(Umap(2)).plot()

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
mkazecommented, Sep 6, 2020

@koaning Let’s close this issue (since I think it’s fully resolved now) and continue the discussion for handling helper vectors in #199.

1reaction
mkazecommented, Sep 2, 2020

@koaning Having implemented and merged this feature, now how do we want to go about handling those pca_0, pca_1, etc. embeddings? Do we want to entirely remove them, or make them optional (e.g. for backwards compatibility) by adding a separate argument in the __init__ method of corresponding transformer classes, e.g. def __init__(self, ..., add_indicators=False)? Or any other option?

Read more comments on GitHub >

github_iconTop Results From Across the Web

plot() function default parameters - Stack Overflow
par() is a functions which has list of parameters, whichever parameter you specify those will be stored inside par() and in turn will...
Read more >
Default Parameter - an overview | ScienceDirect Topics
One common use of default parameters is in I/O library routines (described in Section 7.9. 3). In Ada, for example, the put routine...
Read more >
Default Arguments in Python Functions - Stack Abuse
Function with Default Arguments​​ Default arguments in Python functions are those arguments that take default values if no explicit values are ...
Read more >
Set or Query Graphical Parameters - R
Either an integer specifying a symbol or a single character to be used as the default in plotting points. See points for possible...
Read more >
Plotting Functions for the 'parameters' Package - GitHub Pages
Changing parameter names in the plot. By default, model_parameters() returns a data frame, where the parameter names are found in the column Parameter...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found