All Questions
485
questions
-2
votes
0
answers
80
views
Are there objects for primitive data types? [duplicate]
If the object represents a data type, is the variable for a primitive data type like an integer also an object representing this type, or do objects not represent primitive data types?
// Let's assume ...
0
votes
1
answer
44
views
Python Datatypes
I am accessing the HousePrices.csv dataset. After assigning the dataframe, I am trying to optimize memory, for that I am changing the data types.
To my surprize I am able to change the date object ...
1
vote
1
answer
180
views
Config Sweetviz to force analyze object-type column without conversion
Consider the following short dataframe example:
df = pd.DataFrame({'column1': [2, 4, 8, 0],
'column2': [2, 0, 0, 0],
'column3': ["test", 2, 1, 8]})
df....
0
votes
1
answer
27
views
Object belongs to class and has property in typescript?
import type { Scene, Camera } from 'three'
interface SceneWithActiveCamera extends Scene {
activeCamera: Camera
}
let scene: SceneWithActiveCamera
Is there a simpler way to do this? For example, ...
0
votes
0
answers
48
views
FluentAssertions - Should().BeEquivalentTo() when the mapping expectation is different
I have two classes. SourceDto and TargetModel
public class SourceDto {
public string name {get;set;}
public bool male {get;set;}
}
public class TargetModel {
public string name {get;set;}
public ...
-1
votes
1
answer
64
views
What is the best practice for returning type when the function is making object based on string?
I have the follow function that is retuning an object when a string is provided. I defined as any but I wonder if exists a better type or generic type even when the object structure is unknow
This is ...
1
vote
3
answers
127
views
Type Mismatch Object and Integer
m.CurrDateObject = FindCurrDateObject(m.itemContent.date)
?"title :"m.CurrDateObject.title //Here I got Type Mismatch Error When 0 comes
?"text :"m.CurrDateobject.text
'...
0
votes
1
answer
27
views
ora-6530 reference to uninitialized composite
I created object and procedure
create or replace type rec_int_g as object
( i integer);
create or replace type typ_int_g is table of rec_int_g;
Procedure iparse(v_str in varchar2, t_int out NOCOPY ...
0
votes
1
answer
74
views
Modifying a parent class's constructor parameters and passing them to `super()`
I have a base class, Sprite, and a subclass Player. Sprite's constructor() takes a few parameters, one of which is the path to an image. Player should take all parameters except the image path, and ...
1
vote
1
answer
79
views
Combine multiple objects with different rows
I have the following objects:
> freq
0 1
11027 1264 12291
> wf
total SE
df[[var_name]]0 4327145 98763
df[[var_name]]1 691647 48336
Total ...
2
votes
1
answer
91
views
Combine (binding columns) two objects with different classes
I want to combine the results of 2 objects in R that have same name for each level. I have wf1 object and CI1 object (below) but when I use the cbind command to combine them I don't get all the ...
-1
votes
1
answer
59
views
trouble understanding Params object type in nextJS13
I'm having difficulty understanding the Params type structure of nextJS.
the below code runs fine:
type Params={
params:{userid:string}
}
export default async function UserPage({params:{userid}}:...
0
votes
2
answers
127
views
Consistently iterate API response which may be an object or an array of objects
I have the following JSON code.
{
"Artikelnr":"1000",
"Vooraad_NL":2.0,
"Voorraad_DE":1.0,
"Voorraad_BE":0.0
}
When I loop through the json ...
1
vote
1
answer
141
views
Explicitly infer object as readonly
I have a function which takes in an object
declare function f<T extends object>(body: T): any;
f({
type: "object",
})
Function signature looks like this:
function f<{
type: ...
1
vote
1
answer
136
views
No index signature with a parameter of type 'string' was found on type '{}' - TypeScript
I read key value pairs from a file, the key is string and the value is {r,g,b} numbers.
colorNames.json file:
{
"name1": { "r": 151, "g": 23, "b": 26 },
&...