19,434 questions
2
votes
3
answers
115
views
Perform a random binomial draw for each row in R without rowwise()
I have an R data frame that I need to perform a random binomial draw for each row. The n = argument in the random binomial draw will be based on a value in a column of that row. Further, this ...
0
votes
1
answer
224
views
In Visual Studio 2022, is there a way to output two executables from a single project
I'm using Microsoft Visual Studio 2022 Community edition.
I want to create two executables from the same project using conditional attributes.
Example:
using System;
public class MyClass
{
...
0
votes
1
answer
138
views
R dplyr conditional join with "join_by" not working [closed]
I have to datasets.
One includes service dates with durations for each person (id).
Second includes these persons care episodes with their start and end date.
I need to make a conditional join, ...
0
votes
0
answers
23
views
How do I extend the message area available for a condition message in a Wix 3.11 installation project?
I am using a WixStandardBootstrapperApplication.HyperlinkLargeLicense as the application ref in my installer. It is a WixStandardBootstrapperApplication type with a logo, I have a message that ...
1
vote
2
answers
82
views
Azure pipelines conditions with each loop inside the condition
I have a job in azure-pipelines that receives a variable number of dependencies.
It could have zero dependencies, or "n" dependencies depending what previous jobs were executed before this ...
0
votes
1
answer
134
views
Group of conditions in IF THEN statements in VBA
I have a code that allows the user to know what to do with an item depending on several conditions - there's tens of thousands of items. There are specific exclusions in the code based on very ...
0
votes
1
answer
57
views
Combining multiple OR conditions with AND in Excel formula
I am trying to combine OR conditions with AND over multiple columns in my Excel datasheet and would like advice on how to do this. A sample table is shown below.
The formula does not calculate the two ...
0
votes
1
answer
69
views
Conditionally parse number from text string in and assign to new column
I am attempting to conditionally parse numbers from text strings within a dataframe and then assign that parsed number to the corresponding row within the last column. The condition is grepl("...
0
votes
1
answer
45
views
React how to set active link text color using dynamic conditions
I am trying to build a dynamic nav bar which has 2 states one for when you are on the HomePage and have not yet scrolled and a 2nd for when you scroll down on the HomePage or are on any other page.
I ...
1
vote
1
answer
95
views
Pandas Dataframe: Creating a new column and filling it with values according to 2 conditional statements on other columns
I've written this script that create new columns based on a value meeting two conditions.
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
df=pd.DataFrame()
df['variable 1']= np....
1
vote
3
answers
95
views
Apply each cell of column a condition and replace the value in cells in R
I have the dataframe below:
> last_t_df3
A1BG A2M NAT1 NAT2 SERPINA3
1 1.943765 0.0000000 1.271231 0.0000000 0.0000000
2 1.419931 0.3045321 2.507409 0.0000000 4....
0
votes
4
answers
107
views
Simple JavaScript to make something in range
I am trying to simply move the the cursor so that when it is between 200=x and 300=x the canvas background goes salmon and outside of that range it goes blue.
Here is my full attempt:
<!DOCTYPE ...
1
vote
1
answer
58
views
Filter and compare on grouped rows (tidyverse)
I have a dataframe and I want to find the duplicates, and either choose one row or keep more than one, depending on a column condition.
tst <- data.frame(dataset=as.factor(c(rep("DS1", 4),...
0
votes
2
answers
85
views
Compare both the columns from Text values
I have a data set having IN & OUT columns with text string.
Compared text "Yes", "NA", "N/A", "No", "Partial".
If it is matching both the columns ...
0
votes
1
answer
259
views
Using a condition in Alteryx but doing nothing if none of the conditions match then do nothing
I have a survey that as fields like
"4 - agree"
"3 - neutral"
"2 - disagree"
"1 - completely disagree"
and random comments which consists of open-ended feedback....
1
vote
1
answer
169
views
Conditional check to clear/empty field using Jolt on multiple types of field values
I have the below JSON
[
{
"field1": "xyz",
"field2": "mno",
"res1": "pqrs"
},
{
"field1": "xyz1",
...
0
votes
2
answers
104
views
Excel VBA conditional formatting for certain columns only
I have a table with prices for products. For each product there is one row. For each row there are columns for several companies. Each company has 2 columns - one for old price and one for new price. ...
0
votes
1
answer
765
views
Comfyui, how to create a custom node that dynamically updates the sub-options based on the selected main option
This custom node have a first option (main) to select the type of other options. I can´t get the condition to act as a selector to show a serie of options or the other.
`@classmethod
def INPUT_TYPES(s)...
0
votes
0
answers
49
views
problems validating form with a loop for python
I am trying to validate my fields in a more efficient way and I think I am on the right track, but I have a problem with the for loop, the code is as follows
First of all I manage all the fields ...
1
vote
0
answers
49
views
GCP IAM condition
I granted a user as K8S cluster admin with condition that the resource.name.endsWith("non-prod"), however, the condition does not work, the user still cannot maintain the non-prod clusters
...
-7
votes
2
answers
183
views
How to ignore WHERE in a SQL statement [duplicate]
I have a simple statement:
SELECT *
FROM Articles
WHERE Category = @category
When the @category is 0 or null, I need the WHERE condition to be ignored and SQL select all articles
0
votes
0
answers
66
views
Dealing with confidential modules in a Python code: are conditional imports possible?
Let say I have a Python code with a src source folder. Inside this folder is a subfolder confidential (typically a git submodule) that is confidential and only selected users of the code can access.
I ...
0
votes
5
answers
235
views
How to use two INDEX and MATCH statements to return specific value?
I have a situation where I wish to find the closest value in an array and then use that to lookup another value.
Here is my example.
In cell H4, users can enter a desired value (in minutes [mins]) ...
0
votes
1
answer
109
views
How to highlight mismatching values between sheets in Tableau?
I have two sheets in Tableau that both contain a list of names. I want to highlight the mismatching values (or even matching values if that's easier) between the sheets. Both sheets use the same data ...
-1
votes
1
answer
62
views
Cypress conditional passing the test without running the rest of the code [closed]
So here is the scenario for the Cypress test I need to create:
Visit the website, check if project exist
2a). If it does - change the name and pass the test without running
the rest of the code ...